Can someone show me some code that allows for 2 JTextFields in a JOptionPane with 3 custom button choices? I need to have a User Name and PAssword input, but the rest of the app needs to be locked with this option up. So just a JFrame or an Internal Frame won't work for me. Thanks
Create a JPanel with all the input components you need
Use the showOptionDialog method and use the JPanel you created as the message
When you receive the result, you can get the values of each component individually. Like this:
Just one detail, since all those components are the "message", none of them will start with focus. Hope it helps. Francisco
Francisco<br />SCJP<br />please use the [code][/code] tags when showing code.Click <a href="http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=ubb_code_page" target="_blank">here</a> to see an example.
Alas, poor Yorick, he knew this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop