QB / QB64 Discussion Forum      Other Subforums, Links and Downloads
 

 Return to Index  

And for compiled QBasic programs...

May 3 2002 at 6:17 PM
Zip  (no login)


Response to Accessing command line parameters from qbasic 1.1

 

DECLARE FUNCTION get.psp% ()
DECLARE FUNCTION commandX$ ()
PRINT "Parameters: " + commandX$

DEFINT A-Z
FUNCTION commandX$

a$ = ""
DEF SEG = get.psp
l = PEEK(&H80)
FOR i = &H81 TO &H81 + l - 1
a$ = a$ + CHR$(PEEK(i))
NEXT i
DEF SEG
commandX$ = a$

END FUNCTION

DEFINT A-Z
FUNCTION get.psp

a$ = MKL$(&HB4E58955) + MKL$(&H8B21CD62) + MKL$(&H1D89067E) + MKL$(&H2CA5D)
DEF SEG = VARSEG(a$)
CALL absolute(s%, SADD(a$))
DEF SEG
get.psp = s%

END FUNCTION


    
This message has been edited by iorr5t on May 4, 2002 10:51 AM


 
 Respond to this message   
Responses

 Copyright © 1999-2014 Network54. All rights reserved.   Terms of Use   Privacy Statement  

Newbies usually go to www.qbasic.com and click on The QBasic Forum
Forum regulars have their own ways, which include The QBasic Community Forums