Post by Psycho on Sept 21, 2008 21:33:19 GMT -5
I've used the new button command successfully in several instances but beginning a new project, I've discovered a problem with it. I created a quick dummy program here to demonstrate.
This program works just fine using the link command for #select:
Whereas this program, using the button command for #select, will ask for the input twice before displaying.
In my real program, I clear the screen and reprint the links after every selection so they are always available to the user. When I use the button command in those circumstances, the program never displays the users input and simply keeps asking for the input over and over again.
Odd one.......
John
This program works just fine using the link command for #select:
[mainscreen]
cls
link #select, "Selector", [promptwindow]
print " "
link #quit, "Quit", [quit]
wait
[promptwindow]
input "Enter a number greater than 0 ";repeat
if repeat > 0 then goto [display]
link #start1, "Your number is less than 0. Please try Again", [promptwindow]
print" ":print" "
link #goback, "Clear", [mainscreen]
wait
[display]
cls
print "You entered ";repeat
print:print
button #start, "Clear", [mainscreen]
wait
[quit]
print "Goodbye"
end
Whereas this program, using the button command for #select, will ask for the input twice before displaying.
[mainscreen]
cls
button #select, "Selector", [promptwindow]
print " "
link #quit, "Quit", [quit]
wait
[promptwindow]
input "Enter a number greater than 0 ";repeat
if repeat > 0 then goto [display]
link #start1, "Your number is less than 0. Please try Again", [promptwindow]
print" ":print" "
link #goback, "Clear", [mainscreen]
wait
[display]
cls
print "You entered ";repeat
print:print
button #start, "Clear", [mainscreen]
wait
[quit]
print "Goodbye"
end
In my real program, I clear the screen and reprint the links after every selection so they are always available to the user. When I use the button command in those circumstances, the program never displays the users input and simply keeps asking for the input over and over again.
Odd one.......
John