Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Uppercase file names
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01504494
Message ID:
01504495
Views:
99
This message has been marked as the solution to the initial question of the thread.
See http://www.berezniker.com/content/pages/visual-foxpro/copy-move-rename-file-preserving-destination-name-case

>I am working on a program to prepend a two-letter year code onto an existing file name and then replace the file name.
>
>
>SET DEFAULT TO "C:\Documents and Settings\pthomas\Desktop\0111"
>
>numberoffiles=ADIR(gaFileList,'*.pdf')
>FOR nCount=1 TO numberoffiles
>
>OldName=gafilelist(ncount,1)
>YearCode=substr(oldname,3,2)+"_"
>Newname=upper(yearcode+oldname)
>RENAME (oldname) to (newname)
>
>ENDFOR
>
>
>This works fine except the resulting file name is lower case, whereas the original file name was uppercase. For example, 10AP22B.PDF should become AP_10AP22B.PDF but instead I get ap_10ap22b.pdf.....regardless of what I do with the upper command.
>
>Suggestions?
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform