BBS: Inland Empire Archive Date: 12-23-92 (09:48) Number: 289 From: GLENN DELAHOY Refer#: NONE To: MARK BERTUZZI Recvd: NO Subj: desqview aware source cod Conf: (2) Quik_Bas
> I was wondering if anyone has some dv aware codes which I > can put in my programs. Hi Mark, here's everything I know about DV, not much but it's a start. Regards, Glenn ' DESQview routines for Quick Basic - by Glenn Delahoy DECLARE SUB DvPause () DECLARE FUNCTION DvGetVer$ () ' Define the type needed for Interrupt TYPE RegType ax AS INTEGER bx AS INTEGER cx AS INTEGER dx AS INTEGER bp AS INTEGER si AS INTEGER di AS INTEGER flags AS INTEGER END TYPE DEFINT A-Z CLS ' example for getting DESQview version number ' if DvGetVer$ returns a zero length string then DV is not loaded DvVersion$ = DvGetVer$ IF LEN(DvVersion$) > 0 THEN PRINT "Running under DESQview "; DvVersion$ ELSE PRINT "DESQview is not loaded." END IF ' example for giving up idle time to DESQview ' if DV is not loaded it is ignored ' insert this into an inkey loop or whatever DvPause FUNCTION DvGetVer$ DIM InRegs AS RegType, OutRegs AS RegType InRegs.ax = &H2B01 InRegs.cx = &H4445 InRegs.dx = &H5351 CALL Interrupt(&H21, InRegs, OutRegs) IF (OutRegs.ax AND &HFF) <> &HFF THEN DvGetVer$ = LTRIM$(STR$((OutRegs.bx AND &HFF00) \ 256)) + "." + LTRIM$(STR$(OutRegs.bx AND 255)) END IF END FUNCTION SUB DvPause DIM InReg AS RegType, OutReg AS RegType InReg.ax = &H1000 CALL Interrupt(&H15, InReg, OutReg) END SUB --- FMail 0.92 * Origin: Rough Productions -V32- (059) 983 639 (3:635/572)
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