QBASIC Question

If you have questions about any aspect of QBasic programming, or would like to help fellow programmers solve their problems, check out this board!

Moderators: Pete, Mods

Post Reply
User avatar
Austin
Coder
Posts: 36
Joined: Wed Aug 01, 2007 6:09 am
Location: Colorado
Contact:

QBASIC Question

Post by Austin »

Ok, here is the code:

Code: Select all

1 PRINT "LOGIN:"; : INPUT L$
L$ = UCASE(L$)
IF L$ = "AUSTIN" THEN
PRINT "LOGGED ON AS AUSTIN."
ELSE PRINT "LOGIN NAME INCORRECT, TRY AGAIN."
GOTO 1
END IF
The problem is when it prints out it looks like this:
LOGIN:?

I want it to print like this:
LOGIN:

How would I get rid of the "?".

Regards,
Austin
MystikShadows
Veteran
Posts: 703
Joined: Sun Nov 14, 2004 7:36 am
Contact:

Post by MystikShadows »

Hi Austin,

Here's one thing you can try that might solve your problem

1 PRINT "LOGIN:";: LINE INPUT L$

instead of what you have on line one.

this should make your ? dissapear.

Hope this helps
When God created light, so too was born, the first Shadow!

MystikShadows

Need hosting? http://www.jc-hosting.net

Interested in Text & ASCII development? Look no further!
http://www.ascii-world.com
Anonymous

Post by Anonymous »

You can also do it this way

Code: Select all

INPUT "LOGIN: ",L$
User avatar
Austin
Coder
Posts: 36
Joined: Wed Aug 01, 2007 6:09 am
Location: Colorado
Contact:

Post by Austin »

Sorry for my late response, thanks both of you! Both options worked great, and my Munshkin : Text Adventure game is going along great.

Thanks,
Austin
Post Reply