hi all,
my grid have only single band and i set the property selectTypRow = single..
so please suggest for How to set my active row as selected row (with highlited).
UltraGrid1:SELECTED:Rows:Clear().UltraGrid1:ActiveRow = hRow. /* here hRow is a previos save active row.*/
Thanks in advance...
You can handle the AfterRowActivate event and set the row's Selected property to true.
But why do that? Why deal with both active and selected and go to the trouble of keeping them constantly in synch. If you only need to deal with a single row, why not simply always use the ActiveRow and use the ActiveRowAppearance to highlight it and turn off selection?
I'm having the same issue... How do I turn off selection?
The idea of having active row and select row sync was just to avoid to have 2 rows highlighted when you have a single row selection type.
Thanks,
Monica
Hi,
If you are only concerned with one row, then it's generally a good idea to turn off selection and just use the active row. Otherwise, they can become confusing because they aren't necessarily the same row.
To turn off row selection, you use the SelectTypeRow property on the Override object.
There's an Override on the grid.DisplayLayout which affects all bands, and then there is also an Override on each band.
So to disable row selection for the whole grid, you would do this:
this.ultraGrid1.DisplayLayout.Override.SelectTypeRow = SelectType.None;