How would I go about displaying a JOptionPane.showinputDialog() with multiple JButtons on each line? I am not talking about the Yes, No, Cancel buttons but multiple custom labeled JButtons that displays in the content area of JOptionPane.showinputDialog?
so I would need to get the value of the button pressed from the JOptionPane as well.
You can place any
JComponentsto the JOptionPane, there I can’t see any limits,JOptionPaneis same Top-Level Container asJFrame,JDialogorJWindow, but in contrast with plainTop-Level Containers,JOptionPanehas implemented return events from built-in funcionalities inIntegervalue, meaning buttonsYES,NO,OK,CANCELandCLOSEtoo,put all JButtons to the Array