Microsoft KB Archive/161497

= FIX: SYS(2014) Function Returns Incorrect Path =

Article ID: 161497

Article Last Modified on 10/15/2003

-

APPLIES TO


 * Microsoft Visual FoxPro 3.0 Standard Edition
 * Microsoft Visual FoxPro 3.0b Standard Edition
 * Microsoft Visual FoxPro 5.0 Standard Edition

-



This article was previously published under Q161497



SYMPTOMS
If a file name consists of periods along with the file extension, the SYS(2014) function does not return the correct path. According to the SYS(2014) Help topic, the SYS(2014) function "returns the minimum path relative to the current or specified directory or folder for a specified file."

Note: The word "folder" appears in the Visual FoxPro 3.0 Help file but not in the Visual FoxPro 5.0 Help file.



STATUS
Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem has been fixed in Visual FoxPro 5.0a.



MORE INFORMATION
The SYS(2014) function returns different values depending on the version of Visual FoxPro currently running.

Steps to Reproduce Behavior
 In Visual FoxPro 3.0b, issue the following commands in the Command window:

?SYS(2014,"Samples\Data\........dbf")

?SYS(2014,"Samples\Data\employee.dbf")

The following paths appear on the desktop:

SAMPLES......DBF

SAMPLES\DATA\EMPLOYEE.DBF

-or-

 In Visual FoxPro 5.0, issue the following commands in the Command window:

?SYS(2014,"Samples\Data\........dbf")

?SYS(2014,"Samples\Data\employee.dbf")

The following paths appears on the desktop:

.....DBF

\VFP5\SAMPLES\DATA\EMPLOYEE.DBF



The SYS(2014) function should actually report the following value for the path when a file name consists of period characters:

\SAMPLES\DATA\........DBF

Keywords: kbbug kbfix kbvfp500afix KB161497

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.