Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sendmail by ASP

Status
Not open for further replies.

fsqueeen

Programmer
Jul 8, 2002
43
MY
<html>
<head>
<title>ASPSend mail example</title>
</head>

<body>

<%
'Getting (Requesting) the Session variables from Form on previous page
Session(&quot;FromName&quot;) = Request(&quot;FromName&quot;)
Session(&quot;FromAddress&quot;) = Request(&quot;FromAddress&quot;)
Session(&quot;Subject&quot;) = Request(&quot;Subject&quot;)
Session(&quot;BodyText&quot;) = Request(&quot;BodyText&quot;)

Set Mailer = Server.CreateObject(&quot;SMTPsvg.Mailer&quot;)

'Setting variables
Mailer.FromName = Session(&quot;FromName&quot;)
Mailer.FromAddress = Session(&quot;FromAddress&quot;)

'Mailer.RemoteHost = &quot;smtpmail.activeisp.com&quot;

'change here
'Mailer.AddRecipient &quot;Webmaster Active ISP&quot;, &quot;webmaster@domain.com&quot;

**Mailer.RemoteHost = &quot;abc.cisco.com&quot;
**Mailer.AddRecipient &quot;Webmaster Active ISP&quot;, &quot;abci@cisco.com&quot;
Mailer.Subject = Session(&quot;Subject&quot;)
Mailer.BodyText = Session(&quot;BodyText&quot;)

'Checking if mail sent ok, if not display error message
if Mailer.SendMail then
Response.Write &quot;Mail sent...&quot;
else
Response.Write &quot;Mail send failure. Error was &quot; & Mailer.Response
end if

'Abandoning session variables
Session.Abandon
%>

</body>
</html>

these are the codes i download from a site.
codes with ** is my codes.

and below is the error i got after i execute the codes:

Error Type:
Server object, ASP 0177 (0x800401F3)
Invalid ProgID. For additional information specific to this message please visit the Microsoft Online Support site located at:

Please help me.
 
Have you registered the component properly?

You must open a command prompt (shell), go to the directory where you have installed the ASPMail component, and type
Code:
regsvr32 smtpsvg.dll

Palooka
 
huh?
ok, but i didn't install anything?
du i need to do that too?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top