Post Reply 
Limitation of CHOOSE command
12-31-2013, 01:15 PM
Post: #1
Limitation of CHOOSE command
I/O command CHOOSE. Page 549 of the Prime User Guide.

Up to and including "item14" works.

...,"itemn" is wrong!

With "item15" and beyond you get a Syntax Error.

Someone please prove me wrong.

I need "item1" thru "item20".

It is looking like I will have to write code for a CHOOSE 1 thru 10 and a CHOOSE 11 thru 20. That would not be good programming.

Thanks in advance for any help.

Happy coding and may you see ' i No errors in the program ' with every compilation.
Find all posts by this user
Quote this message in a reply
12-31-2013, 04:58 PM
Post: #2
RE: Limitation of CHOOSE command
Look at the on-calc help for choose. The built in help inside the calculator will nearly always be the most accurate.

Quote:Syntax: CHOOSE(var, “title”, “item1”, “item2”,[…"item14"]) or CHOOSE(var,"title",{"item1"..."itemN"})

Displays a choose box with the given title and containing items with the strings "item1", etc. If the user choose an object, var will be updated to contain the number of the selected object (an integer, 1, 2, 3, …); otherwise, stores zero in var if the user exits without choosing.

Returns true (non zero) if the user selects an object, otherwise return false (0).

Give a list as item #3.

TW

Although I work for HP, the views and opinions I post here are my own.
Find all posts by this user
Quote this message in a reply
12-31-2013, 05:36 PM
Post: #3
RE: Limitation of CHOOSE command
Thanks for the help Tim.

Happy coding and may you see ' i No errors in the program ' with every compilation.
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 2 Guest(s)