Forum Moderators: open
<%
Dim objMessage
Set objMessage = Server.CreateObject("CDO.Message")
HTML = "<!DOCTYPE HTML PUBLIC'-//IETF//DTD HTML//EN'>"
HTML = HTML + "<html>"
HTML = HTML + "<head>"
HTML = HTML + "<title>Sending Email Request for TRIR info</title>"
HTML = HTML + "</head>"
HTML = HTML + "<body>"
HTML = HTML + "<table width='600' align='center' border='0'>"
HTML = HTML + "<tr>"
HTML = HTML + "<td height='40' valign='top'>"
HTML = HTML + "<img border='0' src='Images/formletter/logo.gif' width='110' height='52' valign='top' align='left'><br> "
HTML = HTML + "</td>"
HTML = HTML + "</tr>"
HTML = HTML + "</table>"
HTML = HTML + "</body>"
HTML = HTML + "</html>"
objMessage.From = "xx@xx.com"
objMessage.To = "xx@xx.com"
objMessage.HtmlBody = HTML
objMessage.Subject = "FormLetter"
objMessage.AddAttachment"/attachments/attachment 1.txt"
objMessage.Send()
Response.Redirect( ""+Request.QueryString( "nextpage" ) )
objMessage=nothing
%>
This code works fine, but I want to be able to add the file name as part of email. Currently when I send the email the attachment appears as ATT84302.txt
Any help would be nice.