Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Menu help!
#1
Hello... got a problem with a menu. It is working but not as i want:

Code:
CLS : SCREEN 9

cursorRow = 8
cursorCol = 33
cursorPosition = 1

LOCATE 8, 35
PRINT "New"

LOCATE 10, 35
PRINT "Load"

LOCATE 12, 35
PRINT "Exit"

DO

DO
key$ = INKEY$
LOOP UNTIL key$ <> ""

LOCATE cursorRow, cursorCol
PRINT " "

IF key$ = CHR$(0) + CHR$(72) THEN cursorRow = cursorRow - 2
IF key$ = CHR$(0) + CHR$(80) THEN cursorRow = cursorRow + 2

IF cursorRow = 8 THEN cursorPosition = 1
IF cursorRow = 10 THEN cursorPosition = 2
IF cursorRow = 12 THEN cursorPosition = 3

IF ((cursorPosition = 1) AND (key$ = CHR$(0) + CHR$(72))) THEN cursorRow = 12
IF ((cursorPosition = 3) AND (key$ = CHR$(0) + CHR$(80))) THEN cursorRow = 8

LOCATE cursorRow, cursorCol
PRINT ">"

LOOP

Now, i want so that if the cursor is on "New" and you press the upp-arrow the cursor goes to the "Exit" choice and the same thing when the cursor are at the "Exit" choice but it wont it just keep going up/down, please help.

Oh, and sorry for my bad English.
Reply


Messages In This Thread
Menu help! - by Weasel88 - 02-19-2006, 04:03 AM
Menu help! - by phycowelder - 02-19-2006, 04:22 AM
Menu help! - by Weasel88 - 02-19-2006, 04:28 AM
Menu help! - by phycowelder - 02-19-2006, 08:56 AM
Menu help! - by axipher - 02-19-2006, 11:55 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)