Open topic with navigation
<viz>.input
This command prompts the user to input some text
<viz>.input( |
|
prompt |
value = '' |
) |
|
prompt
A string which is displayed above the input area.
value = ''
A string that will initially show up in the input area.
Remarks
Use this command when you need the user to enter some text. This command will halt all events until the user has finished inputting some text.
Return Value
The value the user entered. The return value will be a string unless the value is a proper number, in which case a number will be returned. To ensure a string is returned and not a number, the user can force a string by surrounding the value in quotes (e.g., '123').
Example
UserName = viz.input('What is your name?')
print('User name is',UserName)
See also