JOptionPane 3 « JOptionPane « Java Swing Q&A





1. Resize JOptionPane    forums.oracle.com

Hi I have a program that prompts a user for an appropriate response via a JOptionPane: action = (String)JOptionPane.showInputDialog(fwmt, "An Alarm has been triggered!\n\n" + "Please specify an appropriate response\n ", "Alarm", JOptionPane.WARNING_MESSAGE, null, actions, "Recycle"); The software is to be used on a touch screen PC and problem is that the JOptionPane small and the drop down list is hard ...

2. html in JOptionpane    forums.oracle.com

3. Problem importing the javax.swing.JOptionPane under linux    forums.oracle.com

Hey guys, I'm used to programming under windows but i wanted to give it a try under linux, there are a few things that can't seem to compile well and I don't know what may be going on. This simple code import javax.swing.JOptionPane; public class Exam { public static void main(String args []) { JOptionPane.showMessageDialog(null, "This is a test"); } } ...

4. JOptionPane and JDesktop Bug?    forums.oracle.com

5. JOptionPane setLocation ???    forums.oracle.com

8. using JOptionPane    forums.oracle.com

9. put the result in JOptionPane    forums.oracle.com





10. JOptionPane    forums.oracle.com

11. try catch block and JOptionPane    forums.oracle.com

Hi guys. I am using JOptionPane.showInputDialog where i ask users to key in some input values, and I have to check. If the users key in values that are not integers, I need to handle it and print out an error message. Should I use the try catch block? How do i specifically detect though that it is not an integer ...

12. JOptionPane.getWindowForComponent()    forums.oracle.com

Window is a superclass of Frame and Dialog. And in 1.6 there is a constructor of JDialog that accept Window as owner, but I can't use it! JOptionPane.getWindowForComponent() is a static method that is not public, and I don't understand the reason! Because when I create a JDialog over a frame or over another dialog, I must use a method like ...

13. Possible jOptionPane Problem?    forums.oracle.com

We have an application which simply plays a sound and shows a jOptionPane with a message when an error occurs. For a very small percentage of our user base (roughly one half of one percent), our program simply exits upon startup. It plays the error sound, so we know the exit process is being called, but no jOptionPane is shown. Does ...

14. JOptionpane    forums.oracle.com

15. get multiple textFieldFrom JOptionPane??    forums.oracle.com

import javax.swing.*; import javax.swing.border.*; import java.awt.event.*; import java.awt.*; class ParamGUIFirst extends JPanel { private JLabel lblHH = new JLabel("HH :"); private JLabel lblD = new JLabel("D :"); private JLabel lblDL = new JLabel("DL :"); private JLabel lblTH = new JLabel("TH :"); private JLabel lblRD = new JLabel("RD :"); private JTextField textFieldHH = new JTextField(5); private JTextField textFieldD = new JTextField(5); private ...

16. adding butons to joption pane    forums.oracle.com





17. JOptionPane help    forums.oracle.com

18. Aligning a JOptionPane ?    forums.oracle.com

My program is an applet. I have a JOptionPane popup when my card game ends. It pops up in the middle of the screen as opposed to the middle of my Container. Is there a way to make that happen, maybe telling it to center in the middle of the container itself??

19. JOption Pane help needed! urgent    forums.oracle.com

For a programming assignment in my AP Comp Sci class, we had to create a method (example: public int BlahBlah (int blah)). The instructions also say to use JOptionPane for inputing the int needed. However, because I created the method, it automatically brings up the method input box, AS WELL as the JOptionPane box I wrote in the code. So, essentially, ...

20. JOptionPane    forums.oracle.com

That argument is the parent component. JOptionPane's are modal which means that they "take over" your application. So when an optionPane is visible the user can't interact with other parts of your application. You see modal dialogs in applications to help control application flow. For example you want a user to see and acknowledge a warning or error. Setting the parent ...

21. Moving your mouse, using a JOptionPane    forums.oracle.com

The only problem is, that I can't move my mouse to the location I want. I heard you could use the Robot class for this, but it didn't work out as I wanted -I guess I screwed the code up-. So I'd like to know how I'm able to move my mouse, left click and right click, all at custom locations, ...