Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
WINMM.DLL and Saving File Names
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00552081
Message ID:
00552434
Views:
14
>Since you're using PUTFILE() (I assumed it was GETFILE()), it's probably because the file name specified doesn't exist. Everthing is correct in the declaration and the call.
>
>I don't think that the PutFile() is the issue at all. I tried this code, which I got from the UT library and it didn't work either. I tried it last night on VFP7 on a Windows 2000 Pro system and then again in my office in VFP6 on a Windows 2000 Pro system. The code can't get any simpler then this. I must be doing something wrong.
>
>DECLARE INTEGER GetShortPathName IN Win32API STRING, STRING, INTEGER
>
>lcLongFile = "c:\program files\somefolder\my file name.doc"
>lcBuffer = SPACE(511)
>lnBufferSize = 511
>lnShortPathLen = GetShortPathName(lcLongFile, @lcBuffer, lnBufferSize)
>
>lcShortPath = LEFT(lcBuffer, lnBufferSize)
>
>MessageBox(lcShortPath,16,[Test])
>
>return
>
>Thanks for any help
>
>DJ :o)

Donald,

The short file name doesn't exist until the file is written to the disk. If the file name doesn't exist yet, there's no short path to return.
George

Ubi caritas et amor, deus ibi est
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform