Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is there an API call to rename a folder
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00178253
Message ID:
00178285
Views:
34
>>>local lcCommand
>>>lcCommand = '[move "' + lcOldDirectory + '" "' + lcNewDirectory + '"]'
>>>run &lcCommand
>>
>>What are the square brackets surrounding your DOS command for?
>
>Rich,
>
>FoxPro has three sets of string delimiters, ', ", and [] tha above line uses them all in order to get lcCommand as a string that can be used by the RUN command. The " tacked around the directory names allows spaces to appear in the name.

I know about Fox's string delimiters, but I'm still wondering why the brackets in the above example. Why wouldn't:

lcCommand = 'move "' + lcOldDirectory + '" "' + lcNewDirectory + '"'

work? Seems to me like you used an extra pair of delimiters.
Rich Addison, Micro Vane, Inc., Kalamazoo, MI
Relax, don't worry, have a homebrew.
- Charlie Papazian, The New Complete Joy of Home Brewing
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform