Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1660
How to find the modified column names in ultragrid?
posted

Hi,

I have an ultragrid as shown in the screen shot below

I am modifying some of the values in the grid like below (highlighted in yellow)

While saving I need to get the modified column names. (Name and Nationality)

Is there any way to find the modified column names?

Thanks in advance

Parents
  • 69832
    Offline posted

    By default, UltraGrid updates rows when a row id deactivated (i.e., user tabs out of that row, or clicks on some other row), or the control loses focus.

    When this happens, the BeforeRowUpdate and AfterRowUpdate events fire. You can handle the BeforeRowUpdate event, which gives you a reference to the row being updated, iterate the cells in that row, and check the UltraGridCell.DataChanged property to determine whether a given cell's value was changed since the last update.

    Also note that UltraGrid exposes an UpdateMode property, which enables you to change the trigger for updates...for example, you could set this property to 'OnUpdate', and cell values will not be updated until you call the control's UpdateData method. In this scenario, you would declare a global variable, say a list of tuples or whatever, and when you update, add the changed column keys in response to BeforeRowUpdate (the event will fire once for each row that was updated).

Reply Children