$ » History » Version 8
Per Amundsen, 01/04/2017 11:58 AM
| 1 | 1 | Per Amundsen | _Added 1.9.0_ |
|---|---|---|---|
| 2 | |||
| 3 | 7 | Per Amundsen | *<notextile>$?*!N="message"</notextile>* |
| 4 | 1 | Per Amundsen | |
| 5 | Prompts the user for input and returns the result. |
||
| 6 | |||
| 7 | _See also [[$input]]._ |
||
| 8 | |||
| 9 | 8 | Per Amundsen | _Can be prefixed with # to ensure the resulted text starts with a channel prefix._ |
| 10 | |||
| 11 | 1 | Per Amundsen | *Parameters* |
| 12 | |||
| 13 | 2 | Per Amundsen | <notextile>*</notextile> - Use a password Editbox. |
| 14 | <notextile>!</notextile> - Use a yes/no dialog which will return [[$true]] if user clicks yes, otherwise [[$false]]. |
||
| 15 | 4 | Per Amundsen | ="message" - Message to display. |
| 16 | 5 | Per Amundsen | N - Try to use the Nth token as the result text. |
| 17 | 1 | Per Amundsen | |
| 18 | *Example* |
||
| 19 | |||
| 20 | <pre> |
||
| 21 | ; Ask the user for his name and print the result. |
||
| 22 | //echo $?="What is your name?" |
||
| 23 | |||
| 24 | ; Ask the user for his password and print the result. |
||
| 25 | //echo $?*="What is your password?" |
||
| 26 | |||
| 27 | ; Ask the use to continue with a yes/no dialog. |
||
| 28 | //echo $?!="Do you want to continue?" |
||
| 29 | 6 | Per Amundsen | |
| 30 | ; Ask for the second token. |
||
| 31 | //tokenize 44 a,b,c | echo -ag Ths second token is $?2 |
||
| 32 | 1 | Per Amundsen | </pre> |