Set Volume, Sys(2027)
These commands were meant to help you handle the differences between directory (folder) conventions on PCs and Macs. Of course, with Visual FoxPro/Mac available only in Version 3, this isn't much of an issue anymore. In fact, these two aren't even included in the VFP 5 or VFP 6 Help files. SET VOLUME is back in the VFP 7 Help.SET VOLUME lets you assign a DOS-type drive name to a Mac volume or folder. SYS(2027) is supposed to convert from DOS notation to Mac notation, but it doesn't.
Usage |
SET VOLUME DriveName TO [ FolderName ] cMacPath = SYS( 2027, cDOSPath ) |
SET VOLUME is really pretty cool. It works in the Windows versions of VFP, too, not just on the Mac. You can use it to assign a shorthand drive name to a particular directory, then refer to that directory using the drive name. We don't think we'd do this in an application, but it is pretty neat while you're developing. We've heard of some problems in network situations, but can't replicate them ourselves. Everything seems to work properly on local drives. On the Mac, of course, this command was an essential part of a cross-platform strategy. |
SYS(2027) doesn't work in Visual FoxPro. Hand it a path and you get back the same path in the same old DOS notation. |
Example |
SET VOLUME q: TO _SAMPLES+"TasTrade" MODI PROJ Q:TasTrade |
See Also |