Click here to Skip to main content
11,568,017 members (35,564 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: Java
I have a jtable with many row and is added into jscrollpanel,

When i add more a row to table, I want to set selection to new row and scrollbar of table must be scrolled to end row to show end row,

I try to use code as below but scrollbar don't scroll to end row.
int curRow = model.getRowCount();
Table.setRowSelectionInterval(curRow -1, curRow -1);
please help me!

Thank in advance
Posted 25-Feb-13 5:52am
Edited 25-Feb-13 5:54am
(no name)34.1K
TorstenH. at 26-Feb-13 1:40am
Can't you just set selection and the table moves to the selected position? Should be so imho.
Shubhashish_Mandal at 26-Feb-13 4:36am
check this
april88t at 1-Mar-13 23:25pm
you can also visit this site
DalliaF at 8-Mar-13 2:32am
try this one also-->

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS

Advertise | Privacy | Mobile
Web03 | 2.8.150624.2 | Last Updated 25 Feb 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100