Ad Code

Responsive Advertisement

Display JInternalFrame form inside JDesktopPane in Java

This tutorial shows how to display a JInternalFrame form inside a JDesktopPane in Java. This feature is very helpful especially in you are working with MDI features in your program.


The first thing to do is to create a JFrame Form in your Netbeans project. In my project, I inserted a toolbar into the JFrame and also add a button inside the toolbar. Remember that the code will be inserted into the button located in your toolbar. Next is to add a jDesktopPane inside your JFrame, this element is used to display the jInternalFrame form. Lastly, make sure that you already added a JInternalFrame form.

Source Code:

For further understanding, The code is located in your JFrame form which is inside the button click method of the toolbar. The JDesktopPane is also added to your JFrame form.


Post a Comment

0 Comments

Close Menu