Hi Friends,
I have used to following code in MouseEnterElement event of UltraGrid.
UltraGridCell cell = e.Element.GetContext(typeof(UltraGridCell)) as UltraGridCell;
I always get the cell as null .
Please help.
Regards,Sid.
Hello Sid,
Could you please let me know what version of our controls you are using? I have try the following code snippet and it does work for me.
private void ultraGrid1_MouseEnterElement(object sender, Infragistics.Win.UIElementEventArgs e) { UltraGridCell cell = e.Element.GetContext(typeof(UltraGridCell)) as UltraGridCell; if (cell != null) { //Some logic } }
Are you sure that you are attaching this event to your UltraGrid?
Sincerely,
Danko
Developer Support Engineer
Infragistics
www.infragistics.com/support
Hi Danko,
Sorry for the late reply. I figured out the solution.
I just had to add the following code to the beginning of the Event.
if (!(e.Element is CellUIElement))
{
return;
}
Thanking You,
Siddharth.