Hi dear rep of telerik,
I have a GridViewComboBoxColumn in my gridview and would like to extract the selected text (given by DisplayMember property) programatically.
here is my column declaration
Dim clubManagerColumn As New GridViewComboBoxColumn
clubManagerColumn.HeaderText = "Club Manager"
clubManagerColumn.DataField = "manager_stuff_id"
clubManagerColumn.DataSource = StaffBindingSource
clubManagerColumn.ValueMember = "staff_id"
clubManagerColumn.DisplayMember = "staff_name"
ClubRadGridView.MasterGridViewTemplate.Columns.Add(clubManagerColumn)
when I try
ClubRadGridView.CurrentRow.Cells("club_address_id").Value
I am getting the value for the DataField property, instead I would like to get the selected value of the DisplayMember property.
thank you!
Hi
I have fixed my original problem (should have looked at the sample sooner), but I still have a question about adding a document panel via code. My code uses the recommended approach:
this.dockingManager.SetDocument(documentPane);
but my new document pane does not appear until I select one of the other/existing document panes. Is there some method (Refresh does not work) which I can call to make sure everything is updated?
Best regards
Marek
colTxt.Filter = new ColumnFilterData(GridKnownFunction.StartsWith);
Now when i enter some text in the filter area the filter does not occur and when i erase the filter string the grid throws an execption stating that the object is not defined (Null)...
Could you put me on your payrole please :)
int idxcur = Int32.MinValue;
int idxold = Int32.MinValue;
if (e.OldRow != null)
idxold = grdSearchResults.Rows.IndexOf(e.OldRow);
if (e.CurrentRow != null)
idxcur = grdSearchResults.Rows.IndexOf(e.CurrentRow);
//last row when tab is pressed so create a new row
if ((idxcur==grdSearchResults.Rows.Count-1 && idxold==Int32.MinValue) || idxcur == idxold)
AddMeANewLine();
This works for me.
If anyone knows how to select the first cell (place it in edit mode) let me know.
hope this help