Qbasicnews.com
way to put var - Printable Version

+- Qbasicnews.com (http://qbasicnews.com/newforum)
+-- Forum: QBasic (http://qbasicnews.com/newforum/forum-4.html)
+--- Forum: QB Discussion & Programming Help (http://qbasicnews.com/newforum/forum-11.html)
+--- Thread: way to put var (/thread-1806.html)



way to put var - Solance - 08-23-2003

is there to put var in the middle of a print?

like

Code:
print "whats that VAR HERE"



way to put var - whitetiger0990 - 08-23-2003

yes

Code:
PRINT "A = " + LTRIM$(STR$(a))
PRINT "A =" + STR$(a)
PRINT "A ="; a

2 min responce time!


way to put var - Solance - 08-23-2003

ok let me give a better example

Code:
print "is that a VAR hum... i wonder"



way to put var - whitetiger0990 - 08-23-2003

if VAR is a str
Code:
PRINT "is that a " + VAR$ + " hum... i wonder"
if VAR is an integer
Code:
PRINT "is that a " + LTRIM$(STR$(VAR)) + " hum... i wonder"

like that?


way to put var - Solance - 08-23-2003

yes thank you


way to put var - whitetiger0990 - 08-23-2003

yes, yourwelcome


way to put var - ak00ma - 08-23-2003

Solance, before you post such kinda question, please read the QB help file. You can find it online, too: http://www.qbasicnews.com/qboho.

Here's the answer for your question:

http://qbasicnews.com/qboho/qckprint.shtml