Here you can find the source of getStrInPane(String message, String title)
Parameter | Description |
---|---|
message | message to be displayed |
title | title of window |
public static String getStrInPane(String message, String title)
//package com.java2s; //License from project: Open Source License import javax.swing.*; public class Main { /**/*from w w w . j a v a2 s . com*/ * This method will display an input dialog box * to receive a string of input from user * * @param message message to be displayed * @param title title of window * @return string input from user */ public static String getStrInPane(String message, String title) { return JOptionPane.showInputDialog(null, message, title, JOptionPane.QUESTION_MESSAGE); } }