BBS: Inland Empire Archive Date: 10-21-92 (17:12) Number: 295 From: SCOTT DRYSDALE Refer#: NONE To: KEVIN POOLE Recvd: NO Subj: Mouse programing Conf: (2) Quik_Bas
Hi. Your kinda lucky you caught me.. Try this: DECLARE SUB mousecall (m0%, m1%, m2%, m3%) TYPE Register 'for CALL INTERRUPT 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 DECLARE SUB Interrupt (intnum AS INTEGER, inreg AS Register, outreg AS Register) DEFINT A-Z SUB mousecall (m0, m1, m2, m3) STATIC DIM regs AS Register regs.ax = m0 regs.bx = m1 regs.cx = m2 regs.dx = m3 Interrupt 51, regs, regs m0 = regs.ax m1 = regs.bx m2 = regs.cx m3 = regs.dx END SUB SUB mouseconfine Border = 1 m1 = 7 'X m3 = 0 'minimum m4 = 309 'maximum mousecall m1, m2, m3, m4 m1 = 8 'Y m3 = 0 'minimum m4 = 189 'maximum mousecall m1, m2, m3, m4 RETURN END SUB m1 = 3: 'Set into calling location mousecall m1,m2,m3,m4 ' X and Y pixel location's are now stored in m3, and m4. --- Maximus 2.01wb * Origin: The BULLpen BBS * Intel 14.4EX (613)549-5168 (1:249/140)
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