Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Copy File and Rename File
Message
From
07/06/2004 09:11:37
 
 
To
24/07/2003 11:44:44
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00813114
Message ID:
00910718
Views:
30
>>>>I need to create a file with uppercase character. This file will be read in a unix system and it must be in upper case. So, my file "File1.txt" must be renamed in "FILE1.TXT". I can rename or copy.
>>>>Someone can tell me if there is a way to obtain this ?
>>>>
>>>>Thanks
>>>
>>>I am not sure I understand but if you just what to change the name to upper case you can use the UPPER() function.
>>
>>I have used Upper() function but the file i see in explorer is lower case. If i select the file and rename it using upper case it remains in upper case
>>I need to do that from fox
>
>Michele,
>
>Just tested this
>
>
>Function FileNameToUpperCase(FileName)
>    declare Integer MoveFile in win32api string @ src, String @ dest
>
>    return !empty(MoveFile(FileName, upper(FileName))
>endfunc
>
Hi Gregory,
This Function works nicely if you add one additional ")" to the end of
this line:
     return !empty(MoveFile(FileName, upper(FileName)))
Thanks for the code!
Terry :)
Previous
Reply
Map
View

Click here to load this message in the networking platform