Anybody willing to help me solve my SMTP bulk e-mailing problem?
Below is the code:
<%
SUBMITTED = Request.Form("SUBMITTED")
If SUBMITTED = "TRUE" Then
COMMENTS = Request.Form("COMMENTS")
' build email message
MM = Chr(10) & Chr(13)
MM = COMMENTS
' build mailing list
Set oRSMem=Server.CreateObject("ADODB.Recordset")
sqlString= "SELECT EmailAddress FROM Member WHERE MailingList = True;"
oRSMem.Open sqlString, objConn
MailList = ""
Do While NOT oRSMEM.EOF
MailList = MailList & oRSMem("EmailAddress") & ";"
oRSMem.MoveNext
Loop
oRSMem.Close
Set oRSMem = Nothing
Set objMsg = Server.CreateObject("CDONTS.NewMail")
objMsg.From = "
[email protected]"
objMsg.BCC = MailList
objMsg.Subject = "Fund News Update"
objMsg.Body = MM
objMsg.MailFormat = 0
If Session("UploadFileName") <> " " Then
' Start parsing Data from Session("UploadFileName")
Dim strData
Dim intIndex
strData = Split(Session("UploadFileName"), ",")
Do until intIndex = Session("IntCounter")
objMsg.AttachFile "C:\inetpub\wwwroot\hfrrf\upload\" & strData(intIndex)
intIndex = intIndex + 1
Loop
End If
objMsg.Send
Set objMsg = Nothing
URL = "Administrator.asp"
Response.Redirect(URL)
End If
%>
<H3>Mass Mailing</H3>
<FORM ACTION="Administrator_email.asp" METHOD=POST>
<INPUT TYPE=HIDDEN NAME="SUBMITTED" VALUE="TRUE">
<H4>Comments:</H4>
<P><TEXTAREA NAME="COMMENTS" ROWS="5" COLS="30"><%=COMMENTS%></TEXTAREA>
<P>
<INPUT TYPE=SUBMIT VALUE="Send ">
<INPUT TYPE=RESET VALUE="Reset">
</FORM>
Thanks