Solved

How do I test a emailing script on my local machine?

Posted on 2008-10-09
5
320 Views
Last Modified: 2013-11-29
Hi Experts,

I have the following script. I want to change the "jmail.Send("mailhost.chep.com")" to a local mail server that runs off my laptop for testing. How can I configure this?

Thanks
<%

  ' Call JMail to handle emailing
 

  '*************************************************

  '*                                               *

  '*   Produced by Dimac                           *

  '*                                               *

  '*   More examples can be found at 		   *

  '*   http://tech.dimac.net                       *

  '*                                               *

  '*   Support is available at our helpdesk        *

  '*   http://support.dimac.net                    *

  '*                                               *

  '*   Our main website is located at              *

  '*   http://www.dimac.net                        *

  '*                                               *

  '*************************************************
 

  Set jmail = Server.CreateObject("JMail.Message")
 
 

  For i = LBound(arrstrTo) To UBound(arrstrTo)

      jmail.AddRecipient arrstrTo(i)

  Next
 

  jmail.AddRecipient "rxng@vcsmc.com"
 

  jmail.From = "rxng@vcsmc.com"

	

  jmail.Subject = "Test"
 

  jmail.HTMLBody = "Test"
 

  jmail.Send("mailhost.chep.com")
 
 
 

'==================END OF CODE TO EMAIL SCHEDULED APPOINTMENTS=======================================
 

%>

Open in new window

0
Comment
Question by:indyng
  • 3
  • 2
5 Comments
 
LVL 26

Expert Comment

by:jar3817
Comment Utility
How about you just change the recipient to some test account at gmail or yahoo?
0
 
LVL 1

Author Comment

by:indyng
Comment Utility
The issue is this line: jmail.Send("mailhost.chep.com")

What is the host if i am using my laptop as the server. I am only testing locally. I want to generate the email and send it to outlook.

Thanks
0
 
LVL 26

Expert Comment

by:jar3817
Comment Utility
"localhost" or "127.0.0.1"
0
 
LVL 1

Author Comment

by:indyng
Comment Utility
Like this? Thanks
<% @ LANGUAGE = VBSCRIPT %>

<html>

<body>

<%

  ' Call JMail to handle emailing
 

  '*************************************************

  '*                                               *

  '*   Produced by Dimac                           *

  '*                                               *

  '*   More examples can be found at 		   *

  '*   http://tech.dimac.net                       *

  '*                                               *

  '*   Support is available at our helpdesk        *

  '*   http://support.dimac.net                    *

  '*                                               *

  '*   Our main website is located at              *

  '*   http://www.dimac.net                        *

  '*                                               *

  '*************************************************
 

  Set jmail = Server.CreateObject("JMail.Message")
 
 

  jmail.AddRecipient "rxng@vcsmc.com"
 

  jmail.From = "rxng@vcsmc.com"
 

  jmail.Subject = "This is a test"
 

  jmail.HTMLBody = "Hello there"
 

  jmail.Send("127.0.0.1")

%>
 

Mail sent..

</html>

Open in new window

0
 
LVL 26

Accepted Solution

by:
jar3817 earned 500 total points
Comment Utility
Assuming you have a mail server listening on your local computer that will accept mail for vcsmc.com, yes.
0

Featured Post

Want to promote your upcoming event?

Are you going to an event? Are you going to be exhibiting at a tradeshow? Talking at a conference? Using a promotional banner in your email signature ensures that your organization’s most important contacts stay in the know and can potentially spread the word about the event.

Join & Write a Comment

Microsoft has released various new features which are capable of handling various tasks. One of these tasks is ‘Migration from pop3 to Exchange Server’. Pop3 data stores various data along mailboxes like contacts, tasks, etc. So, it becomes the need…
Local Continuous Replication is a cost effective and quick way of backing up Exchange server data. The following article describes the steps required to configure Local Continuous Replication. Also, the article tells you how to restore from a backup…
Familiarize people with the process of utilizing SQL Server stored procedures from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Micr…
The basic steps you have just learned will be implemented in this video. The basic steps are shown to configure an Exchange DAG in a live working Exchange Server Environment and manage the same (Exchange Server 2010 Software is used in a Windows Ser…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now