The mail was sent with the attachments of 10286 KB (10.04 MB)
But, The mail was not sent with the attachments of 15356 KB (14.99 MB) but the attachments were attached to the application successfully and I did not receive any error.
I have done the following in my ASP.Net application
Web.Mail.SmtpMail.SmtpServer = "10.2.3.6"
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate", 1)
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendusername", "xxx@xxx.com")
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendpassword", "xxxxxxxxx")
mail.To = "xxx@xxx.com"
mail.From = "xxx@xxx.com"
mail.Subject = "text"
mail.Bodyformat = System.Web.Mail.Mailformat.Html
mail.Priority = System.Web.Mail.MailPriority.Normal
Dim strHTML As String
strHTML = "<html><head></head><body><a href="url" target=_new>" & "Click Here</a></body></html>"
mail.Body = strHTML
Dim Dr1 As SqlDataReader
SqlCmd.Connection = SqlConn
Dr1 = GetRecordSet(SqlCmd, "procedure name")
While Dr1.Read
If Dr1.Item("OriginalFile") <> "" Then
mail.Attachments.Add(New MailAttachment(baseLocation & Dr1.Item("JobID") & "_" & Dr1.Item("OriginalFile")))
'baseLocation is string which contains the path
End If
End While
Dr1.Close()
Web.Mail.SmtpMail.Send(mail)
I have uploaded the file to the server and stored the path in the DataBase
I have checked the SMTP Mail servers mail message size limit using same SMTP server and user name, password in the outlook express. I checked by sending an email with 20.56 MB attachments using outlook express. It was sent and received successfully.
I have also unchecked "Limit message size to and Limit session size to" checkboxes under the "Messages" tab of the "Default Virtual Server SMTP Properties" dialog in the IIS 5.1.
I have done the following in the machine.config,
<configuration>
<system.web><httpRuntime executionTimeout="18000" maxRequestLength="2097151"/>
</system.web>
</configuration>
But its not working, instead I am getting the following error while sending mail with 22.33 MB of attachments
"Your email message to <advertising@wimaonline.com> with the subject of ABC00700 - New Job From (Yost) was unable to be sent because the connection to your mail server was interrupted. Please open your email client and re-send the message from the Sent Messages folder
and I have also tried the following in my asp.net code,
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout", 18000)
and tried the following also,
mail.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout", 60)
but still I am getting the "connection to your mail server was interrupted" error from "Symantec email proxy"
Any help would be appreciated
Thanks.
Balaji S