Scroll bars on table component


Recommended Posts

Hi,

Is there any way to reset the vertical scroll bar on a table component back to the top programatically? I have various sizes of text arrays being read into a table component on a pop up page. If the user scrolls down to read the text to the bottom and leaves the scroll bar at the bottom when they clear the pop up page then the next time the page is popped up the scroll bar is still at the bottom so if the text array is small then it will be scrolled off the viewable area until the user scrolls back up.

Before the text array is filled with the new text from disk I clear each line of existing text with a For loop from 0 to Numrows(TextArray) If I could set the number of rows in the now empty text array to a low number less than the size of the table component in rows would this make the vertical scroll bar disappear, and if so would it reappear at the top if my table in this case needed it?

Thanks

Link to comment
Share on other sites

There is no built in way to do it. You may, however, be able to trick the system into it using the method you describe or something similar. I'd imagine that if you made it so there was no data in the table, wait long enough for the page to refresh, then repopulate the table, that would reset it to the top, but the page would have to refresh, and the page would have to be visible.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.