Forums Register Login

JTable - Tab Displacement

+Pie Number of slices to send: Send
In JTable how to change
the tab displacemant from column to row because by default the when you hit
tab it jumps from one column to another but i want from one row to another.
Thanx in Advance
+Pie Number of slices to send: Send
hi bala,
i feel u should add keyListener to ur JTable and in keyReleased event u should check if the code of pressed is VK_TAB
& if it is so u should change the focus to the next row using
int oldrow = table.getSelectedRow();
table.setSelectedRow(oldRow+1);
hope this helps
regards
deekasha
+Pie Number of slices to send: Send
I realize this is an old thread, but maybe it will surface again. My question is how do you make JTable tabbing tab only between cells that are editable. The Sitraka LiveTable accomplishes this by providing a traversable property. If JTable can't do this, what about an alternative to Sitraka (their prices are going up and it's becoming cost-prohibitive).
+Pie Number of slices to send: Send
 

Originally posted by deekasha gunwant:
hi bala,
i feel u should add keyListener to ur JTable and in keyReleased event u should check if the code of pressed is VK_TAB
& if it is so u should change the focus to the next row using
int oldrow = table.getSelectedRow();
table.setSelectedRow(oldRow+1);

hope this helps
regards
deekasha



I am unable to add KeyListener to cell of JTable. Can anyone please show me a sample example of how should I add KeyListener to cell ?
Seriously Rick? Seriously? You might as well just read this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 1450 times.
Similar Threads
tabbing in JTable
Jtable
tabbing in JTable
Validating JTable Cell
JTable Cell and Tab Problem[jdk1.3 ]
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 06:50:35.