Server.ScriptTimeout = 1000
Dim intSelGroupID
Dim strEmailBody
Dim strSubject
Dim strEmailAddress
Dim strMemUserName
Dim lngNumberOfMembers
Dim blnLCode
Dim strMainForumName
Dim strForumEmailAddress
Dim intEmailSentLoopCounter
Dim strMailComponent
Dim strIncomingMailServer
strSQL = "SELECT timescfg.* From timescfg;"
rsConn.Open strSQL, adoCon
blnLCode = CBool(rsConn("lcode"))
strMainForumName = rsConn("bbsname")
strForumEmailAddress = rsConn("masteremail")
strMailComponent = rsConn("mailcomponent")
strIncomingMailServer = rsConn("smtpserver")
If blnMassMailier = False Then
rsConn.Close
Set rsConn = Nothing
adoCon.Close
Set adoCon = Nothing
Response.Redirect("menu.asp")
End If
rsConn.Close
intSelGroupID = CInt(Request.Form("group"))
strEmailBody = Request.Form("message")
strSubject = Request.Form("subject")
If intSelGroupID = 0 Then
strSQL = "SELECT timesuser.Username, timesuser.useremail "
strSQL = strSQL & "From timesuser "
strSQL = strSQL & "WHERE timesuser.useremail '';"
Else
strSQL = "SELECT timesuser.Username, timesuser.useremail "
strSQL = strSQL & "From timesuser "
strSQL = strSQL & "WHERE timesuser.grpid = " & intSelGroupID & " AND timesuser.useremail '';"
End If
rsConn.CursorType = 3
rsConn.Open strSQL, adoCon
%>
群发邮件
群发邮件
返回到管理主菜单
你可以给所有的用户或者特定的用户组广播邮件
lngNumberOfMembers = rsConn.RecordCount
Response.Write("The email's are being sentDo not Hit Refresh or some members will receive the email twice!This may take some time depending on the speed of the mail server and how many email's there are to send.")
Response.Write("There are email's sent out of a total of " & lngNumberOfMembers & "")
Do While NOT rsConn.EOF
intEmailSentLoopCounter = intEmailSentLoopCounter + 1
strEmailAddress = rsConn("Username")
strMemUserName = rsConn("useremail")
Response.Write(vbCrLf & "document.frmSent.sent.value = " & intEmailSentLoopCounter & ";")
Call SendMail(strEmailBody, decodeString(strEmailAddress), decodeString(strMemUserName), strMainForumName, decodeString(strForumEmailAddress), strSubject, strMailComponent, false)
rsConn.MoveNext
Loop
Response.Write(vbCrLf & "Your email's have now been sent.")
rsConn.Close
Set rsConn = Nothing
adoCon.Close
Set adoCon = Nothing
%>