Post Reply 
[help] input cmd
10-14-2016, 02:20 PM (This post was last modified: 10-14-2016 10:08 PM by compsystems.)
Post: #3
RE: [help] input cmd
Thanks Cyrille

PHP Code:
export testInput()
begin
 local x1
:= 9x2:=8x3:=7x4:=6;
 print();
 print(
"Enter x1 value > "); wait();
 
//if NOT( input( x1 ) ) then kill; end;
 
while true do
  if 
NOTinputx1 ) ) then break; end;
 
end;
 print(
x1); 

 print(
"Enter x2 value > "); wait();
 
//if NOT( input( x2 ) ) then kill; end;
 
while true do
  if 
NOTinputx2 ) ) then break; end;
 
end;
 print(
x2);

 print(
"Enter x3, x4 values > "); wait();
 if 
NOTinput( { x3x4 } ) ) then killend;
 print(
x3);
 print(
x4);

 print(
"any key to continue");
 return 
"done";
end

It is a good trick =)
Code:
while true do if NOT( input( x2 )) then break; end; end;
The dialog box is called again, but the second run is necessary to press the [cancel] to exit =( and the [ok] key does not respond, also you lost the option to terminate the program =(
Code:
if NOT( input( x1 ) ) then kill; end;


I think the INPUT command for a single entry, the [OK] button should not execute the box, simply enter the data, a second [ok] executes it, just as is done with INFORM (HP48 / 50).
For multiple inputs [OK] button should to jump to the next entry

if NOT( input( { x3, x4 } ) ) then kill; end;

Another option or idea is add a new submenu
[Edit] [] [] [] [cancel] [ok] (current)->
[Edit] [ok] [] [] [cancel] [exe]
Good ideas?


PD: In the above code is required not in capital letters, I would like to accept it also in small letters for next uptated of firmware

There is a command to print without skip line? PRINT_LINE
I want to show the out, immediately after the input message.
print("Enter x2 value > ")
Enter x2 value > 8
and not
Enter x2 value >
8
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
[help] input cmd - compsystems - 10-14-2016, 01:43 AM
RE: [help] input cmd - compsystems - 10-14-2016 02:20 PM
RE: [help] input cmd - compsystems - 10-14-2016, 02:57 PM



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