Logo

Hacker’s Guide to Visual FoxPro
An irreverent look at how Visual FoxPro really works. Tells you the inside scoop on every command, function, property, event and method of Visual FoxPro.

SET CURSOR, Sys(2002), Sys(2008), Sys(2009)

These commands and functions all relate to the keyboard cursor. SET CURSOR and SYS(2002) let you turn it on and off under certain circumstances. The other two don’t do anything in Visual FoxPro (or FoxPro for Windows)—in FoxPro for DOS, they let you change the cursor shape.

Usage

SET CURSOR ON | OFF
SYS(2002 [, 1 ] )

Without the optional parameter, SYS(2002) is identical to SET CURSOR OFF—both turn off the keyboard cursor. (They don’t affect the mouse cursor.) With the parameter, it turns it back on, just like SET CURSOR ON. However, they affect the cursor only when certain commands are executing. The only one of those commands you’re likely to use in VFP is WAIT, but only its most basic form is affected; if you use WAIT WINDOW, these commands don’t affect you.

Way back in FoxBase+ days, we used this stuff occasionally to exercise more control over what the user saw. In Windows, it doesn’t make any sense at all. Don’t do this.

See Also

DragIcon, MousePointer, Set, Set Mouse