>Discovered quite mysterious situation in VFP7( don't remember in VFP6 ). When .exe is run from Wise InstallerMaster 8.14 doing some post install tasks then certain functions returning current directory or including it such as
>
>sys(5)+curdir()
>or
>sys(16)
>
>return sort of Dos path c:\outbou~3 instead of c:\outbound123
>When the same .exe is run from Windows Explorer the directory returned is okay.
>Any clues what's going on and how to overcome it?
>
>Thank you
>Michael
Michael,
What would it matter. In any case they're same dirs. But if you're desperate to correct it you could use winAPI :
DECLARE integer GetLongPathName IN WIN32API ;
string @ lpszShortPath, string @ lpszLongPath, integer cchBuffer
DECLARE integer GetShortPathName IN WIN32API ;
string @ lpszLongPath, string @ lpszShortPath, integer cchBuffer
lcDir = SYS(5)+CURDIR()
STORE SPACE(300) TO lpszShortPath, lpszLongPath
lnLen = GetShortPathName(lcDir,@lpszShortPath, 300)
? SUBSTR(lpszShortPath,1,lnLen)
lnLen = GetLongPathName(SUBSTR(lpszShortPath,1,lnLen),@lpszLongPath,300)
? SUBSTR(lpszLongPath,1,lnLen)
Cetin