• Post Reply Bookmark Topic Watch Topic
  • New Topic

setting taborder

 
Yogesh Dhond
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How do i set the taborder of the Jtextfields within the JFrame?
 
jay vas
Ranch Hand
Posts: 407
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well if youre using a JTabbedPane, you just add the tabs
in the order which you want them to be displayed.

i.e.

//displays a frame with two tabs.
public static void main(String[] args)
{
JFrame f = new JFrame();
JTabbedPane j = new JTabbedPane();
j.addTab("Panel 1" , new JPanel());
j.addTab("Panel 2" , new JPanel());

f.getContentPane.add(j);

f.setVisible(true);
}

-j
 
Michael Dunn
Ranch Hand
Posts: 4632
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!