# Form script error



## ashras99 (Jul 13, 2002)

I am creating a "Quote request form" And this is the script in ASP:

Script
*****
<%
dim bodymessage
bodymessage = "Hi,
You have received a New Reservation. The details are given below.

"
bodymessage = bodymessage & "*Contact Information*
"
bodymessage = bodymessage & "Your Name: " & request.form("realname") & "
"
bodymessage = bodymessage & "E-mail Address: " & request.form("email") & "
"
bodymessage = bodymessage & "Phone: " & request.form("phone") & "
"
bodymessage = bodymessage & "Phone Ext: " & request.form("ext") & "
"
bodymessage = bodymessage & "Fax: " & request.form("fax") & "
"
bodymessage = bodymessage & "Your Address: " & request.form("address") & "
"
bodymessage = bodymessage & "City: " & request.form("city") & "
"
bodymessage = bodymessage & "State: " & request.form("state") & "
"
bodymessage = bodymessage & "Zip: " & request.form("zip") & "
"
bodymessage = bodymessage & "Company: " & request.form("company") & "
"
bodymessage = bodymessage & "Comments: " & request.form("comments") & "
"
bodymessage = bodymessage & "*Part 1*
"
bodymessage = bodymessage & "Manufacturer: " & request.form("mfg1") & "
"
bodymessage = bodymessage & "Part No: " & request.form("partno") & "
"
bodymessage = bodymessage & "Quantity: " & request.form("quantity1") & "
"
bodymessage = bodymessage & "Delivery: " & request.form("delivery1") & "
"
bodymessage = bodymessage & "*Part 2*
"
bodymessage = bodymessage & "Manufacturer: " & request.form("mfg2") & "
"
bodymessage = bodymessage & "Part No: " & request.form("partno2") & "
"
bodymessage = bodymessage & "Quantity: " & request.form("quantity2") & "
"
bodymessage = bodymessage & "Delivery: " & request.form("delivery2") & "
"
bodymessage = bodymessage & "*Part 3*
"
bodymessage = bodymessage & "Manufacturer: " & request.form("mfg3") & "
"
bodymessage = bodymessage & "Part No: " & request.form("partno3") & "
"
bodymessage = bodymessage & "Quantity: " & request.form("quantity3") & "
"
bodymessage = bodymessage & "Delivery: " & request.form("delivery3") & "

"

Set Mail = Server.CreateObject("Persits.MailSender")
Mail.Host = "smtp.xxx.com"
Mail.Port = 25
Mail.From = "[email protected]"
Mail.FromName = "Reservation Details"
*Mail.AddAddress = "[email protected]"*
Mail.Subject = "Reservation Details"
Mail.Body = bodymessage
Mail.IsHTML = True
Mail.Send
%>

But this script giving a following error, please tell me what's wrong in this:

_Microsoft VBScript runtime error '800a01b6'

Object doesn't support this property or method: 'AddAddress'

/sendmail.asp, line 230​_
Line 230 mentioned as bold. Please tell me what need to change...


----------



## Rockn (Jul 29, 2001)

Do you have the Persist email component as well? Your script will not work without it.

I also believe your *Mail.AddAddress = "[email protected]"* needs to be *Mail.Address = "[email protected]"*

Nevermind, just take out the = sign and it should work *Mail.AddAddress "[email protected]"*


----------



## ashras99 (Jul 13, 2002)

What is persistent email component. I removed the "=" sign but still giving following error:

Persits.MailSender.4 error '800a0006'

550 5.1.1 <[email protected]> User unknown; rejecting

/sendmail.asp, line 234


----------



## Rockn (Jul 29, 2001)

That is the ASP mail component you need installed on your web server to get this script ot run. [email protected] is not a real user if you have an internal mail server.


----------



## ashras99 (Jul 13, 2002)

where i get the ASP mail component, is that freely available. Please tell me the link...and how to use that. And what's the error mean.


----------



## Rockn (Jul 29, 2001)

You can get it from where you got the script from.


----------



## ashras99 (Jul 13, 2002)

I get the script from my friend and he is not available to explain me how to use, where to get the component. Can you help?


----------



## Rockn (Jul 29, 2001)

Google > Persits.MailSender = results


----------



## ashras99 (Jul 13, 2002)

I searched the net and find out many tutorials...on this and nowhere mentioned that I required a ASP mailcomponent for this. Btw, I am still getting following error....what this mean?

Persits.MailSender.4 error '800a0006'

550 5.1.1 <[email protected]> User unknown; rejecting

/contactus.asp, line 219


----------



## ashras99 (Jul 13, 2002)

I can write my yahoo address and any smtp server that forwards the mail to yahoo account, so that i can check is that script working fine or not.


----------



## ashras99 (Jul 13, 2002)

Any can help me regarding the error and this script.


----------



## Rockn (Jul 29, 2001)

This is not a real email address:
550 5.1.1 <[email protected]> User unknown; rejecting
Tyr entering a legit email address as well as SMTP servre. A lot of mail servers do not allow forwarding or relaying so this script may not work for you at all. Ask your ISP if this can run on their servers or not.


----------



## ashras99 (Jul 13, 2002)

My ISP said that you can run this script on the server and ASP mail component is also installed on the server. So, what can be the root of this error.


----------

