sun javadocs say :-
showInputDialog
public static Object showInputDialog(Component parentComponent,
Object message,
String title,
int messageType,
Icon icon,
Object[] selectionValues,
Object initialSelectionValue)
throws HeadlessExceptionPrompts the user for input in a blocking dialog where the initial selection, possible selections, and all other options can be specified. The user will able to choose from selectionValues, <b><i>where null implies the user can input whatever they wish, usually by means of a JTextField.</i></b>
initialSelectionValue is the initial value to prompt the user with. It is up to the UI to decide how best to represent the selectionValues, but usually a JComboBox, JList, or JTextField will be used.
The one in Bold says we can use Jtextfield....
How do I use JTextfield for the showInputdialog method in JOptionPane?
Thanks again