We help IT Professionals succeed at work.

Persits email script not working

Bruce Gust
Bruce Gust asked
on
1,197 Views
Last Modified: 2010-05-18
Below is the code I'm using in the context of ASPMail (Persits). It's not working. I'm thinking it's because I'm asking it to send an email from an address that's not on my server, although I can't tell.

I don't get an error message, just no email.

What do you think?

Set Mail = Server.CreateObject("Persits.MailSender")
      Mail.Host = "mail.brucegust.com"
         Mail.From = "jessica@sonicflood.com"
         Mail.AddAddress Request.Form("email")
         Mail.Subject = "your customer login page..."
         Mail.Body = emailbody
      Mail.IsHTML = False
         Mail.Send ' send message
      Set Mail = Nothing
Comment
Watch Question

Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Commented:
Change the username and password accordingly.
Bruce GustPHP Developer

Author

Commented:
We're on to something, but we're not quite there yet.

I applied your suggestion and the test email went through without a hitch.

However...

Here's the error I'm getting when I tried to apply your concept into the code I'm working with...

Persits.MailSender.4 error '800a0006'

550 <bruce@bigshinyplanet.com> No such user here

/Sonicflood/ShoppingTransfer.asp, line 232


...and here's my code...

emailbody = "You can access the status of your purchases, as well as any downloadable resources by going out to <A HREF=""http://www.brucegust.com/Sonicflood/Customer/default.htm"" target=""target=_blank""> " _
& "http://www.brucegust.com/sonicflood/Customer/default.htm</a><P>If you have any questions, contact Jessica at <A HREF=""mailto:jessica@sonicflood.com"">jessica@sonicflood.com</a>.<P>Thanks!"

Set Mail = Server.CreateObject("Persits.MailSender")
Mail.Host = "mail.brucegust.com"
Mail.From = "jessica@sonicflood.com"
Mail.AddAddress "bruce@bigshinyplanet.com"
Mail.Subject = "your customer login page..."
Mail.Body = emailbody
Mail.IsHTML = False
Mail.Username = "bruce@brucegust.com"
Mail.Password = "drumst1ck"
Mail.Send ' send message
Set Mail = Nothing

What am I missing?

Commented:
Is bruce@bigshinyplanet.com a valid email address?
Bruce GustPHP Developer

Author

Commented:
Yes, it is. Is there any problem with the script sending a message from "jessica@sonicflood.com", yet the mail server is "mail.brucegust.com?"
Bruce GustPHP Developer

Author

Commented:
I'm thinking this is a relay issue in that my server wouldn't send an email from an email address that referenced a different server. I remedied that by just sending a generic email from my server plus the password / username suggestion that was mentioned.

Thanks!

Commented:
Adding the following code fixed this for me too, thank you!

Mailer.Username = "USERNAME"
Mailer.Password = "PASSWORD"

Gain unlimited access to on-demand training courses with an Experts Exchange subscription.

Get Access
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Empower Your Career
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.