GeeCON Prague 2014*
The moose likes Swing / AWT / SWT and the fly likes How can I customised the Ok-Cancel Button in JOptionPane Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "How can I customised the Ok-Cancel Button in JOptionPane" Watch "How can I customised the Ok-Cancel Button in JOptionPane" New topic
Author

How can I customised the Ok-Cancel Button in JOptionPane

Rohit Kedia
Ranch Hand

Joined: Apr 24, 2010
Posts: 79
Can I make this size like the Above Search Button


[Thumbnail for untitled.jpg]

Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
really looks like you should be using a modal JDialog (instead of the simplified JOptionPane),
then you can easily do just about anything you want with it.
Rohit Kedia
Ranch Hand

Joined: Apr 24, 2010
Posts: 79
Sir ,
But I have to used JOptionPane only because I have here a popup actually a JPanel from where user can select a User Info by Searching and after selecting that information he can add that in the JTextField.

So thats why I had shifted from JFrame to JOptionPane.

For that also I had raised Posts earlier in this Forum.
I had been sugessted to use a JOptionPane and which actually worked perfectly.
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19697
    
  20

But now your requirements have changed, and therefore also the solution.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
GeeCON Prague 2014
 
subject: How can I customised the Ok-Cancel Button in JOptionPane