getSingleChoiceIndex

HC GUI programming Standard Dialogs getSingleChoiceIndex
getSingleChoice MessageBox

getSingleChoiceIndex message caption choices
(getSingleChoiceIndex message caption choices pos centre size)


Operation to show a dialog to choose one of multiple choices.

message is the input promt text.

caption is the window title text.

choices is a list of items which may be lists or words to select from.

pos is a list of two integer numbers representing x and y position.

If centre is true, the message text (which may include new line characters) is centred; if false, the message is left-justified.

size is a list of two numbers representing width and height.

Output is the zero-based index representing the selected string. If the user pressed cancel, -1 is returned.

Example:

show (getSingleChoiceIndex [A Message][A Caption]
	[[Choice Nr. 1][Second Choice][Third Choice]])

Reference:

getSingleChoice MessageBox