Asp > Code Snippets
show how to send an attachment with your e-mail .
show how to send an attachment with your e-mail . <% Dim objCDONTS 'create an instance of the object Set objCDONTS = Server.CreateObject("CDONTS.NewMail") 'senders emial address objCDONTS.From = "myaddress@email.com" 'recipients email address objCDONTS.To = "someonelses@email.com" 'this is your subject (title of email) objCDONTS.Subject = "here is the file" 'file to be attached objCDONTS.AttachFile "d:\myfile.txt" 'main text body objCDONTS.Body ="Here is the file we promised" 'send the email objCDONTS.Send Set objCDONTS = Nothing %>
Asp Codes
ActiveX
ADO
Array
Code Snippets
Components
Data Access
Date Time
Files
Graphics
HTML Formatting
Mathematics
Miscellaneous
Sessions
SQL
Strings
Techniques
XML