BBS: Inland Empire Archive Date: 07-22-92 (13:20) Number: 105 From: FRANCOIS ROY Refer#: NONE To: ROB MINCEY Recvd: NO Subj: Re: QBSWAP Conf: (2) Quik_Bas
RM> CASE 2 ' Shell to DOS RM> CLS ' Clear screen RM> SHELL ' Shell command RM> Replace the SHELL statement with a CALL DOSSHELL("") SUB DOSSHELL (R$) STATIC REM Issue a Doss Shell to run program X$ with command line R$ C$ = ENVIRON$("COMSPEC") + CHR$(0) IF R$ = "" THEN R$ = CHR$(0) + CHR$(0) ELSE R$ = R$ + " " + CHR$(0) RC% = 0: G$ = "TMP.TMP" + CHR$(0) CALL SetShell RC% = QBSWAP%(C$, R$, RC%, G$) CALL FixShell IF RC% AND 0 = ASC(R$) THEN SHELL ' Normal shell if no swapper END SUB Note that this will work in a compiled .EXE but NOT under the QB environment. The other requirement is to link your .EXE by naming SWAP.OBJ *first*, followed by your own program's .OBJ. The result (SWAP.EXE) can be renamed to whatever you want your program to be called. --- ME2_1104 * Origin: Out of String Space - the Final Frontier (Fidonet 1:163/506.2)
Books at Amazon:
Back to BASIC: The History, Corruption, and Future of the Language
Hackers: Heroes of the Computer Revolution (including Tiny BASIC)
Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution
The Advent of the Algorithm: The Idea that Rules the World
Moths in the Machine: The Power and Perils of Programming
Mastering Visual Basic .NET