表头:
(getBillCardPanel().getHeadItem("head1").getComponent()).setFocusable(true);
or
(getBillCardPanel().getHeadItem("head1").getComponent()).requestFocus();
表体:
getBillCardPanel().getBillTable().requestFocus();
getBillCardPanel().getBillTable().setRowSelectionInterval(1, 1);
getBillCardPanel().getBillTable().setColumnSelectionInterval(2, 2);
或
javax.swing.SwingUtilities.invokeLater(new Runnable(){
public void run() {
// TODO Auto-generated method stub
getBillTable("table").editCellAt(mRow, mCol);
getBodyItem(mKey).getComponent().requestFocus();
}
});