I understand how to create an instance of a JDialog, but are they properly displayed the same way as a JFrame. Is all I have to do to make it function properly just set it to visible? Should anything else be done? Is this this correct and easiest way?
Share
Before you display your
JDialog, you should probablypackit. Also, if you did not supply an owner for theJDialogwhen you created it, you should usesetLocationRelativeTo(owner)to make it pop up in the center of the owner.