You should definitely change the code to something like this
dim fs, loadfile, movefile
loadfile = "E:\Inetpub\wwwroot\uploads\" &
frmSend.Fields.Item("attach1").Value & ".doc"
movefile = "E:\Inetpub\wwwroot\uploads\named\" &
frmSend.Fields.Item("LName").Value & ".doc"
set fs=Server.CreateObject("Scripting.FileSystemObject")
fs.MoveFile loadfile,movefile
set fs=nothing
--
Paul Whitham
Certified Dreamweaver MX2004 Professional
Adobe Community Expert - Dreamweaver
Valleybiz Internet Design
www.valleybiz.net
"ihsutd" <webforumsuser@macromedia.com> wrote in
message
news:faes3c$sca$1@forums.macromedia.com...
>I am trying to copy an uploaded document from one
directory to another. The
> uploaded file (attach1) will be dynamically named. The
resulting file
> (LName)
> name is based on a last name field. I have the following
code but I cannot
> figure out how to deal with the issue of quotation
marks. Should I escape
> them
> or do I use another method?
>
>
> dim fs
> set fs=Server.CreateObject("Scripting.FileSystemObject")
> fs.MoveFile
>
"E:\Inetpub\wwwroot\uploads\<%=(frmSend.Fields.Item("attach1").Value)%>.doc","E:
>
\Inetpub\wwwroot\uploads\named\<%=(frmSend.Fields.Item("LName").Value)%>.doc"
> set fs=nothing
>