Reputation: 11
I am using the JFrame feature in NetBeans in order to make it simpler to customize and edit. In my program, clicking a button calls an action that displays a dialog box. I want to have an image inside of that dialog box. In NetBeans along with its JFrame editor you can add boxes and customize them, along with a dialog box. Which means it will be easier to edit that dialog box.
How to I call that custom dialog box to display when the button is clicked?
To put it more simply without the need for puting code. I have created a cusome dialog box in netbeans GUI builder. Now, how to I call/use that custome dialog box inside of my actual JFrame, which was also coded inside the netbeans GUI editor, and is located inside the same package and all.
Upvotes: 1
Views: 11890
Reputation:
First Drag and drop Swing Windows >> Dialog. Then inside your code write this line to show it
jDialog1.setVisible (true);
After that double click on the Dialog design and add as many components as you like
Best Wishes
Upvotes: 1