Post Reply 
input from user
10-12-2015, 07:03 AM
Post: #2
RE: input from user
Hello,

> user input from the normal input line. Even msdos lets me do this.

But windows does not :-)

Prime is a GUI system, not a command line based system (although it is closer to it than windows).


User inputs in prime are either through the command line WHEN THE PROGRAM IS CALLED. As arguments to your program (MyProgram(args))
Or you need to spawn a GUI to get an input.

Prime does not have a console like dos does, your program can, for example, be called from the program catalog screen. At that point, there is no command line, no console...

INPUT is a very easy way to get data from the user (even if it's full screen). I mean INPUT(MY_Well_Named_Variable) is very simple and very efficient.
If you want a string, things are a little bit more complex as you need to tell INPUT to restrict the types of input that the user can enter (it tries to do too much for you by default).
INPUT({{My_String_Var, [2]}}) will do that, create a full screen INPUT that will request a string from the user and store it in My_String_Var

I hope that this helps.

Cyrille

Although I work for the HP calculator group, the views and opinions I post here are my own. I do not speak for HP.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
input from user - ji3m - 10-11-2015, 07:21 PM
RE: input from user - cyrille de brébisson - 10-12-2015 07:03 AM
RE: input from user - ji3m - 10-12-2015, 12:31 PM
RE: input from user - ji3m - 10-13-2015, 03:03 AM



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