filename = #SearchDept#_#Div#_#fdate#
Main Topics
Browse All TopicsI need to be able to upload and rename a file one it's uploaded. I need to rename the entire file. This is what I have but I get a error. I have a form that browse for a word doc, excell or pdf file. I have a department, division and some dates that I need to remame the document from. This information is in the submit button. Once It comes over I need to rename the document with this information. I hope I explaned it correctly.
Thanks
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
the error you see is a bit misleading in a way that it could just as well be a problem with destination, not just source. cf just shows same error for both... or at least it used to - and we don;t know which cf version you are on...
could be several things:
1) invalid filename - the name you are trying to rename the file to contains invalid characters like / or \ or others
2) permissions problem (unlikely, though, since it's the same directory the file is uploaded to...)
3) file locking - cf has not released the lock on the file after uploading it yet
to rule out 1) and 2) you can try doing copy+delete original instead of renaming:
<!--- copy file to a file with new name --->
<cffile action = "copy"
source = "D:\Inetpub\wwwroot\eas\co
destination = "D:\Inetpub\wwwroot\eas\co
<!--- delete original --->
<cffile action="delete" file="D:\Inetpub\wwwroot\e
if it still does not work, then it's likely file locking...
Azadi
Business Accounts
Answer for Membership
by: azadisaryevPosted on 2009-11-05 at 08:52:53ID: 25751425
something like this?
a_reports\ report\#cf ile.server file#" a_reports\ report\#fd ate & tdate & cdate#.#cffile.serverFileE xt#">
<!---Rename--->
<cffile action = "rename"
source = "D:\Inetpub\wwwroot\eas\co
destination = "D:\Inetpub\wwwroot\eas\co
what is the required pattern of filename?
Azadi