INPUTDLG Input dialog box.
ANSWER = INPUTDLG(PROMPT) creates a modal dialog box that returns user
input for multiple prompts in the cell array ANSWER. PROMPT is a cell
array containing the PROMPT strings.
INPUTDLG uses UIWAIT to suspend execution until the user responds.
ANSWER = INPUTDLG(PROMPT,NAME) specifies the title for the dialog.
ANSWER = INPUTDLG(PROMPT,NAME,NUMLINES) specifies the number of lines for
each answer in NUMLINES. NUMLINES may be a constant value or a column
vector having one element per PROMPT that specifies how many lines per
input field. NUMLINES may also be a matrix where the first column
specifies how many rows for the input field and the second column
specifies how many columns wide the input field should be.
ANSWER = INPUTDLG(PROMPT,NAME,NUMLINES,DEFAULTANSWER) specifies the
default answer to display for each PROMPT. DEFAULTANSWER must contain
the same number of elements as PROMPT and must be a cell array of
strings.
ANSWER = INPUTDLG(PROMPT,NAME,NUMLINES,DEFAULTANSWER,OPTIONS) specifies
additional options. If OPTIONS is the string 'on', the dialog is made
resizable. If OPTIONS is a structure, the fields Resize, WindowStyle, and
Interpreter are recognized. Resize can be either 'on' or
'off'. WindowStyle can be either 'normal' or 'modal'. Interpreter can be
either 'none' or 'tex'. If Interpreter is 'tex', the prompt strings are
rendered using LaTeX.
Examples:
prompt={'Enter the matrix size for x^2:','Enter the colormap name:'};
name='Input for Peaks function';
numlines=1;
defaultanswer={'20','hsv'};
answer=inputdlg(prompt,name,numlines,defaultanswer);
options.Resize='on';
options.WindowStyle='normal';
options.Interpreter='tex';
answer=inputdlg(prompt,name,numlines,defaultanswer,options);
See also DIALOG, ERRORDLG, HELPDLG, LISTDLG, MSGBOX,
QUESTDLG, TEXTWRAP, UIWAIT, WARNDLG .
Documentation for inputdlg
doc inputdlg