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
453
Formatting a perticular row in the WinGrid
posted

Hello,

This is in connection with my earlier post on Adding a New Unbound Row to WinGrid. Please refer to my Post as well as reply for the background scenario.

Now, based on the description, the new order in my ultragrid is actually in 2 states.

1. Pending: Order placed, waiting for admin approval

2. Approved: Order approved.

Now, I need to color the orders pending approvals. Once the orders are approved, the row color is reset to the default ones. Currently I have reset the color of the rows as WHITE background with BLACK as text color. I can color the rows at perticular index in the grid. But when the grid is sorted or grouped, the color is not(as it is colored based on indexes).

Can anyone suggest how should it be done?

Thanks a lot!

Parents
  • 469350
    Suggested Answer
    Offline posted

    It's not a good idea to rely on the Index of a row, since the index can change. You should probably base the appearance of the row on a value of a cell within that row. You might also want to use the ListObject or ListIndex property of the row which return the underlying data object that the row is bound to or the index of that object in it's collection, respectively.

Reply Children