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
120
How to test if RowUIElement is FirstRow or LastRow?
posted

In my DrawFilter routine I'm returning elements that are of RowUIElement.  Before I draw the custom borders for the RowUIElement, I need to test if it's the first or last row.  How would I test the RowUIElement for this condition?

  • 12773
    Verified Answer
    posted

    Hello,

    You can get the current index of the row by getting the row object form RowUIElement:
    RowUIElement uieRow = (RowUIElement)drawParams.Element;
           Int currIndex = uieRow.Row.Index;

    The index will help you to determine the row position in the grid , like 0 is the first row, the grid’s row count minus one will give you the last row index.

    I hope this helps.

    Sincerely,
    Dimi
    Developer Support Engineer
    Infragistics, Inc.