TIP: Click on subject to list as thread! ANSI
echo: quik_bas
to: JOHN ZORTMAN
from: NIGEL TRAVES
date: 1998-03-17 12:14:00
subject: Old FAQ 2 2/5

'>>> Page 2 of QBPSEUDO.FAQ begins here.
*>  "How do I make QB45 stop converting COMMAND$ to uppercase?"
    One method is to obtain a addon lib that provides direct access to
    the PSP and the unconverted command line.  The LIB I released in
    5/94 on the Quick_Basic net provides this and it is free.  This
    method provides the same capability in the design environment as
    well as when the file is compiled, the patch mentioned next does
    not.  The second method is to apply a patch to one of your QB45
    files. The following patch for QB45 will prevent QB from forcing the
    command line to uppercase.  Once you make this patch, you will have
    to use UCASE$(COMMAND$) to retreive an uppercase only string.
    The following steps will extract the OSCMD.OBJ file from your
    BCOM45.LIB, modify it and then replace it with the modified version.
    As always, MAKE A BACKUP OF BCOM45.LIB FIRST!  One note, this will
    not affect the design environment, it will still force to uppercase.
    When the BAS file is compiled and linked, it will return the command
    line as typed.  I still have not found the correct patch to QB.EXE.
    First, enter the following command:
        LIB BCOM45 *OSCMD
    Then run the following basic program
        Search$ = ""
        FOR X% = 1 TO 10
                READ Y%
                Search$ = Search$ + CHR$(Y%)
        NEXT X%
        Replace$ = CHR$(235) + CHR$(8) + STRING$(8, 144)
        PRINT "OSCMD.OBJ ";
        OPEN "OSCMD.OBJ" FOR BINARY AS 1
        X$ = SPACE$(LOF(1))
        GET 1, , X$
        X% = INSTR(X$, Search$)
        IF X% = 0 THEN PRINT "Not Modified.": CLOSE : END
        MID$(X$, X%) = Replace$
        PUT 1, 1, X$
        CLOSE : PRINT "Modified.": END
        DATA 60,97,114,6,60,122,119,2,52,32
    Now enter the following command:
        LIB BCOM45 -OSCMD +OSCMD,,BCOM45
    You should now have a modified BCOM45.LIB.
*>  "How do I make QuickBasic exit with an ErrorLevel?"
    Add the following declare statement at the beginning of your
    program:
        DECLARE SUB ExitWithErrLvl ALIAS "_exit" (BYVAL ERRORLEVEL%)
    Then to exit with an Error level contained in a variable:
        ExitWithErrorLvl Oops%
    WARNING: DO NOT USE THIS WHILE IN THE DEVELOPEMENT ENVIRONMENT IT
    WILL EXIT TO DOS WITHOUT PROMPTING FOR A SAVE.  IT HAS ON OCCASION
    LOCKED UP MY XT AND MY 386 WHEN USED IN THE ENVIRONMENT.
*>  "How do I load QB with two LIBs?"
    You can't.  You must combine the two LIBs into one and load that one
    instead.  This is a common situation that there are routines in the
    stock QB.LIB you need as well as an addon at the same time.  Here is
    how you combine two LIBs and generate a third to use.
      This combines QB.LIB and FOO.LIB into MYLIB.LIB generating a
      MYLIB.CAT catalog file:
            LIB QB.lib +FOO.LIB,MYLIB.CAT,MYLIB.CAT
    Now we must take the combined MYLIB.LIB and generate MYLIB.QLB:
            LINK /q MYLIB.LIB,MYLIB.QLB,nul,BQLB45 ;
    Note that the above lines assume that the current directory is your
    directory that contains QB45 and all the files, if not you must
    provide complete paths to all files not in the current directory.
*>  "Are there any good books on QuickBasic?"
    Yes,  probably the most recomended is:
      "MicroSoft QuickBasic Bible"
'>>> Page 2 of QBPSEUDO.FAQ ends here. Continued on next page.
-+- OLMS 2.53 UNREG
---
---------------
* Origin: Most Wanted BBS +44 (0)1522 887627 & 887628 * (2:2503/509)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.