Problem with MoveFile command in an ASP page

R

RSH

I have an ASP page that needs to move a file from one directory to another.
The code is quite simple but I can't seem to get it to work. I keep getting
a "Download Error: Procedure call or argument is not valid." error when it
hits the movefile part of the code.

What am I missing?


Dim fso = CreateObject("Scripting.FileSystemObject")

strFile1 = "C:\\Inetpub\\wwwroot\\20060118-QuarterlyReports-05112006.rpt"

strFile2 =
"C:\\Inetpub\\wwwroot\\Archive\\20060118-QuarterlyReports-05112006.rpt"

If fso.fileexists(strFile1) Then

fso.MoveFile(strFile1, strFile2)

End If



Thanks!

Ron
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,904
Latest member
HealthyVisionsCBDPrice

Latest Threads

Top