Help with OPEN/WRITE/CLOSE statement
Posted: Sun Sep 23, 2007 3:58 pm
I keep getting an error that says "type mismatch" but everythings perfect...someone wanna look at my code and figure it out?
Code: Select all
CLS
' menu
PRINT "(2) ADD"
PRINT "(1) SEARCH"
'my INKEY statment
kp$ = INKEY$
IF kp$ = "2" THEN GOTO Addp
IF kp$ = "1" THEN GOTO searchp
'This is the end of the menu
'This adds people to the database
addp:
CLS
INPUT "Age:", age$
INPUT "Name:", name$
INPUT "Personality:", per$
INPUT "Pasttimes:", past$
INPUT "Comment:", com$
OPEN database.txt FOR OUTPUT AS #1
WRITE #1, age$, name$
WRITE #1, per$
WRITE #1, past$
WRITE #1, com$
CLOSE #1
searchp:
[code/]
by the way its not done =)