Thank you George,
This is really helpful.
>>Is there a way to convert long file name and directory in the DOS 8 characters format?
>>ex:
>>c:\program files\autocad R14
=> c:\progra~1\autoca~1>
>A couple of things, including the WSH, can get this. If it's not installed, then:
DECLARE INTEGER GetShortPathName in win32api;
> STRING @lpsource, STRING @lptarget, INTEGER nLength
>lcbuffer = SPACE(260)
>* lcfilename is the long filename
>lnresult = GetShortPathName(@lcfile, @lcbuffer, LEN(lcbuffer))
>IF lnresult > 0
> ? LEFT(lcbuffer, lnresult)
>ENDIF
>* With the WSH
>oFSO = CREATEOBJECT('Scripting.FileSystemObject')
>oFile = oFSO.GetFile(lcfile)
>IF NOT ISNULL(oFile)
> ? oFile.ShortName
>ENDIF