0
CDOSYS with Attachment error
LEGEND
,
/t5/dreamweaver-discussions/cdosys-with-attachment-error/td-p/836319
Jun 05, 2006
Jun 05, 2006
Copy link to clipboard
Copied
Hi,
I have set up an email script using CDOSys which works fine. I now want to
add the option of sending an attachment with the email but I cannot get it
to work. I am including the line in my code as follows:
MyMail.AddAttachment Request.Form("MyFile")
This is grabbing the file path enetered in a filefield on the previous page
and then posted to the email page.
After reading numerous articles on this subject this method seems to be the
way to do it but it doesn't send the attachment. I am only testing locally.
I don't get an error when the script is run and when I view the email in
mailroot it does include a blank attachment but the attachment it sends is a
.DAT file. Mine should be a .txt file.
Can anyone point out where this going wrong please.
I have set up an email script using CDOSys which works fine. I now want to
add the option of sending an attachment with the email but I cannot get it
to work. I am including the line in my code as follows:
MyMail.AddAttachment Request.Form("MyFile")
This is grabbing the file path enetered in a filefield on the previous page
and then posted to the email page.
After reading numerous articles on this subject this method seems to be the
way to do it but it doesn't send the attachment. I am only testing locally.
I don't get an error when the script is run and when I view the email in
mailroot it does include a blank attachment but the attachment it sends is a
.DAT file. Mine should be a .txt file.
Can anyone point out where this going wrong please.
TOPICS
Server side applications
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
Newsgroup_User
AUTHOR
LEGEND
,
LATEST
/t5/dreamweaver-discussions/cdosys-with-attachment-error/m-p/836320#M151647
Jun 06, 2006
Jun 06, 2006
Copy link to clipboard
Copied
The file the user is attaching must be on your server. If the
user is
sending a file from your server, be sure the path is correct. If the file
is on the user's computer, it must first be uploaded to the server, then
attached to the e-mail.
"Herman" <herman@nomailme.com> wrote in message
news:e60pst$l43$1@forums.macromedia.com...
> Hi,
> MyMail.AddAttachment Request.Form("MyFile")
>
> This is grabbing the file path enetered in a filefield on the previous
> page and then posted to the email page.
sending a file from your server, be sure the path is correct. If the file
is on the user's computer, it must first be uploaded to the server, then
attached to the e-mail.
"Herman" <herman@nomailme.com> wrote in message
news:e60pst$l43$1@forums.macromedia.com...
> Hi,
> MyMail.AddAttachment Request.Form("MyFile")
>
> This is grabbing the file path enetered in a filefield on the previous
> page and then posted to the email page.
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

