Forum Stats

  • 3,876,221 Users
  • 2,267,082 Discussions


JTable Changes visible area upon Refresh

1027618 Member Posts: 1
edited Jul 28, 2013 3:09PM in Java Desktop Applications

Hi All,

I am having a jTable in a jScrollPane. A refresh button in jPanel to refresh the data in the jTable.

Now the problem is when I refresh the table data the visible area changes for example:

The top row before refresh is row #10, AFTER refresh the top row become a random row number that can be row# 5,7,13,16...

The jScrollPane is scrolling the visible rows.

How can i prevent this and can ensure that the top row in table remains the same after refreshing the table data?

Many Thanks,



This discussion has been closed.