Im understanding getCell method gets rowIdx and colIdx.
I want to get last row and first column. example getCell(“lastRow”, 1).
I can get last row staticly. example getCell(3, 1) 3 is last row in table
But what if i dont know last row in table dynamiccly?
im creating score card which is only gets last row and first column’s value. Table’s data is refreshable and if user select getCell(3, 1) then clicked refresh button data is refreshed. Two row added in data(again i dont know how many row added). Now last row is no longer 3. it’s 5. How to i get last row? im stuck
Thank you for contacting us.
Please note that the component uses the virtual grid, which is responsible for rendering only rows and columns visible to the user. It allows visualizing thousands of rows without freezing the page. Still, it limits the number of cells available for the mentioned
getCell API call. The cell may not be returned if it is not currently rendered or cached in the memory. Therefore, even knowing the last row/column of the table does not always allow to obtain its actual value.
Instead, we suggest checking out the following forum thread, describing the workaround for a similar functionality: https://www.flexmonster.com/question/show-subtotal-and-grand-total-in-first-row-in-classic-form/. The sample mentioned in this thread demonstrates how to automatically scroll the table to the last row/column and restore the position afterward.
We hope it helps.
Your example is scrolling to last row. but it’s not selecting any row. i dont need to scroll to total rows or columns. i just need to select last row. u told me “Therefore, even knowing the last row/column of the table does not always allow to obtain its actual value.”. so is it imposibble?
Thank you for your feedback. We replied to your latest question via email.
Please contact us if other questions arise.
I responded your email.
This question is now closed