Hi,
I do not know where to post this, either in win grid or the tool bars option.
Anyway, I have a grid that has 5 rows. If i select(left click) the second row, the active row would be "1" - which is right. but with the implementation of a popupmenutoolbar, if i right click on the 5th row, the fifth row gets highlighted but the active row is still 1. So I wanna know if it's possible to get the index of the highlighted row instead of the active row.
Hi Mike,
Thank you so much! @.@ I'm stupid, I didn't thin of that... Agora was a contracting company we used prior to deciding to inhouse develop the code. = / My fault...
Regards,
Aaron
I can't run your sample. It's relying on your own Agora.Framework.Win.UI.InfragisticsHelpersm which is relying on an old version of the Infragistics assemblies which I don't have, so it won't run.
I'd be interesting in seeing the source code for the InfragisticsHelper.UltraGridShowPopupOnMouseUp method. Something in there must be changing the grid's selection.
http://www.mediafire.com/?uummyovtwwz
I've uploaded the file in the above link. I am somewhat working around it by reselecting all the cells that was deselected by the popup of the menubar. The only thing I need to do would be to hide the highlighting of the pop-up menu.
And yea, thanks for the grid.rows.selected, but I no longer need it as I started reselecting all the cells instead of activating the row where the menu bar pop-uped.
demigod1 said:Lastly, you didn't answer the question: is it possible just to get the highlighted row instead of the active row? -- I'm assuming not.
Oops, sorry, almost missed it again. :)
Yes, you can use grid.Rows.Selected to get the collection of selected rows. But you really should not have to. In fact, I don't see how that will help you, since the rows are getting de-selected, anyway.
No, I didn't try this with a PopupMenu. But I cannot see how they could possibly make any difference. The PopupMenu doesn't know anything about the grid and so therefore it cannot be changing the grid's selection.
How are you assigning the PopupMenu to the grid? Via the extender properties on the ToolbarsManager? Or are you displaying the PopupMenu in code? If the latter, what event are you using?
If you can provide a sample that demonstrates that a PopupMenu is affecting the selection in the grid, then I'd love to take a look at it, but I don't see how it's possible.