PDA

Click to See Complete Forum and Search --> : [RESOLVED] QBASIC question


pSY cO.
May 29th, 2006, 02:59 PM
Alright. I have three SUBS (so far) in my program. I want one of the SUBS to activate a labeled line in the main module. Here is a code for one of my SUBS.

QBASIC Code:
----------------------------------
SUB CmdPrmpt
---COLOR 15
---13, 1
---PRINT "Command Prompt"
---INPUT "Command"; cmd$
---SELECT CASE cmd$
------CASE "exit"
---------END
------CASE "restart"
---------GOTO 220
------CASE "menu"
---------GOTO 1
-------CASE "cheat"
---------CheatMenu
---END SELECT
END SUB


The turquoise is the line that I want to go back to the main module and *work*

The red, in case you didn't know, goes to a different SUB (just wanted to clear that up)

{ THE WHITE DASHES BEFORE LINES ARE JUST THERE AS SPACES (indents) }

pSY cO.
May 29th, 2006, 04:04 PM
i resolved it all ready... sorry!

si_the_geek
May 29th, 2006, 04:12 PM
{ THE WHITE DASHES BEFORE LINES ARE JUST THERE AS SPACES (indents) }There's no need to do that, you can just use Code tags.. either using the button in the post editor screen, or by putting them in manually, like this: acode] 'code here a/code]