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) ENDFORThis 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.