I am using an UltraWinGrid on a form to let users change data. The last column in the grid is a string but in the grid's BeforeExitEditMode I have some code to validate the data. If it is not in the format that I expect I set e.Cancel to True. However if the user is in the last cell of the last row of the grid, enters invalid data and tabs out, the next control in the tab order is selected. It works as expected for the last cell in any other row. I have the TabNavigation property set to NextControlOnLastCell and it seems like the cancelation of the BeforeExitEditMode event is being ignored for the last cell in the grid.
Any suggestions would be appreciated.
Thank you,
Matt
Hi Matt,
Thank you for the update.
If this workaround is not working then you should upgrade to a newer version where this issue is fixed.
Let me know if you have any additional questions.
Dimitar,
I tried the work around and it exhibits the same behavior. The cursor leaves the last cell in the last row even when I set e.Cancel to True. Thank you for your time.
Hello Dimitar,
Thank you for the information and your proposed workaround. I am going to try it and I'll let you know if I can get it to work.
Regards,
Thank you for the reply.
It seems that this is an old issue that is currently resolved in our newer versions. I have found the issue in our issue tracking system and the issue should be fixed in 8.2 and higher. What you could try as a workaround is to use the cell’s editor ExitEditMode event, instead of the grid’s ExitEditMode (subscribe to it in AfterEnterEditMode event, using the ActiveCell’s EditorResolved property and unsubscribe in the AfterExitEditMode, to prevent memory leak). If that doesn’t fix the issue my suggestion would be to upgrade to later version.
Thanks for the quick response. I should have been specific about the version of the Infragistics controls that I am using. We are using version 8.1. Is there a way that you could try to reproduce the issue using that version?