$ » History » Version 10
Per Amundsen, 02/16/2023 05:11 PM
| 1 | 9 | Per Amundsen | _Added in 1.9.0_ |
|---|---|---|---|
| 2 | 1 | Per Amundsen | |
| 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 | 10 | Per Amundsen | table(ktable). |
| 14 | |*Parameter*|*Description*| |
||
| 15 | | <notextile>*</notextile> | Use a password Editbox. | |
||
| 16 | | <notextile>!</notextile> | Use a yes/no dialog which will return [[$true]] if user clicks yes, otherwise [[$false]]. | |
||
| 17 | | ="message" | Message to display. | |
||
| 18 | | N | Try to use the Nth token as the result text. | |
||
| 19 | 1 | Per Amundsen | |
| 20 | *Example* |
||
| 21 | |||
| 22 | <pre> |
||
| 23 | ; Ask the user for his name and print the result. |
||
| 24 | //echo $?="What is your name?" |
||
| 25 | |||
| 26 | ; Ask the user for his password and print the result. |
||
| 27 | //echo $?*="What is your password?" |
||
| 28 | |||
| 29 | ; Ask the use to continue with a yes/no dialog. |
||
| 30 | //echo $?!="Do you want to continue?" |
||
| 31 | 6 | Per Amundsen | |
| 32 | ; Ask for the second token. |
||
| 33 | //tokenize 44 a,b,c | echo -ag Ths second token is $?2 |
||
| 34 | 1 | Per Amundsen | </pre> |