ASP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreASP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old July 9th, 2003, 09:21 PM
creepingdeath creepingdeath is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 1 creepingdeath User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Exclamation Asp / Jmail Loop Need Help

Hello
Iam some what new to asp and programing. I have put together this code, so I can send out a mailing list to some users. The code looks and seams to run fine. But I dont receive any test messages during when I execute it. it's like the SMTP sever is not sending the emails.

Any help would be great. Cheers.

Creepy


------------------------------------------------------------------

Response.Write ("Newsletters are being created")
Response.Write ("<p>")

Dim strRecipient
Dim strFrom
Dim strSubject
Dim strBody
Dim Jmail


'loop through entries
While not rsEmailAddress.EOF
'get the results from the newsletter form
strFrom = Session("svFrom")
strSubject = Session("svSubject")
strBody = Session("svMessage")

strRecipient = rsEmailAddress.Fields.Item("EmailAddress").Value

'create an instance of the Jmail object
Set Jmail = Server.CreateObject("JMail.SMTPMail")
'set Jmail various properties
JMail.ServerAddress = "smtp.domainname.com"
JMail.ContentType = "text/html"
JMail.AddRecipientBCC strRecipient
JMail.Sender = strFrom
JMail.Subject = strSubject
JMail.Body = strBody
JMail.addHeader "Originating-IP", Request.ServerVariables("REMOTE_ADDR")
Jmail.Execute
'print message for every entry
Response.Write ("message sent to " & strRecipient & "<br>")
'move to next entry in database
rsEmailAddress.MoveNext
Wend
'message to admin saying creation has completed
Response.Write ("<p>")
Response.Write ("newsletter creation completed

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreASP Programming > Asp / Jmail Loop Need Help


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway