SYS(2027)
2007-02Feb-20
FoxPro has a great history of remaining backward compatible. Yet, sometimes the behaviour changes without that the documentation reflects this. SYS(2027) is still available in VFP 9, although it's not documented anymore. The syntax for SYS(2027) is:
cPathOut = SYS(2027,cPathIn)Back when Visual FoxPro was really a cross platform development tool, you would use SYS(2027) to convert the internally used DOS path into a platform specific path. On FPM this functions returns a Mac-compatible path, on FPU a SCO Unix compatible path.
In VFP 9 SYS(2027) works like LOWER(FULLPATH()). The passed string is combined with the current directory. Dots and forward slashes are normalized and the whole string is converted into lower case. With the change in VFP 3 you have to be more careful about what you pass to the function. If you pass a valid Mac path such as "::", FPD simply ignored it. In Visual FoxPro you get an "Invalid file or path name" error.