Quantcast
Channel: swing – Examples Java Code Geeks
Viewing all articles
Browse latest Browse all 18

Get/Set selected tab in JTabbedPane

$
0
0
With this tutorial we shall show you how to get or set the selected tab in a JTabbedPane component of a Java Desktop Application. Basically all you have to do for it is to: Create a new JFrame. Call frame.getContentPane().setLayout(new GridLayout(1, 1) to set up grid layout for the frame. Use JTabbedPane(JTabbedPane.TOP) to get a JTabbedPane. Use tabbedPane.getSelectedIndex() to get the index […]

Viewing all articles
Browse latest Browse all 18

Trending Articles