Dear Group,
I have the following problem:
After editing a Cell in a JTable i want the next cell (i.e. the cell below
the edited cell) to be focused.
I tried the follwing which didnt work:
i overwrote the JTable method editingStopped,
public void editingStopped(ChangeEvent e){
super.editingStopped(e);
this.requestFocus(); // In order to have the focus afte editing stopped
with a JCombobox Celleditor
KeyboardFocusManager k =
KeyboardFocusManager.getCurrentKeyboardFocusManager();
k.focusNextComponent();
//alternatively i tried this.transferFocus();
}
But it didnt work.. Alnybody has some hints how i
can solve my problem or how the focus can be set to any
cell within the table?
Thanks alot for your time and you help,
cheers,
ElimGarak
Christian Kaufhold - 01 Sep 2005 11:56 GMT
> I have the following problem:
> After editing a Cell in a JTable i want the next cell (i.e. the cell below
> the edited cell) to be focused.
table.changeSelection(row, column, false, false);
Christian