RosettaCodeData/Task/User-input-Graphical/PowerBASIC/user-input-graphical.basic
2023-07-01 13:44:08 -04:00

14 lines
414 B
Text

FUNCTION PBMAIN () AS LONG
result$ = INPUTBOX$("Enter a string.")
MSGBOX result$
DO
'This assumes that 75000 is the ONLY valid input.
result$ = INPUTBOX$("Enter the number 75000.")
IF VAL(result$) <> 75000 THEN
MSGBOX "You need to enter 75000!"
ELSE
MSGBOX "You entered the right number."
EXIT DO
END IF
LOOP
END FUNCTION