Wrox Programmer Forums
|
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 26th, 2004, 08:54 PM
Authorized User
 
Join Date: Feb 2004
Posts: 71
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to mahulda
Default Problem witht Sending e-mails

I am trying to send e-mails from my page using the following lines of code

<%@ impport NameSpace System.Web.mail %>

dim srcaddr as string = "[email protected]"
dim destaddr as string = "[email protected]"
dim mailsubject as string = "Test"
dim mailbody as string = "This is a Test"

SmtpMail.Send(srcaddr,destaddr,mailsubject,mailbod y
)


However no mail gets send.
I read somewhere that the Default SMTP server needs to be configured by opening
the Internet Services Manager.
I cant figure out where this Internet Services Manager is.
Can anybody advise me on this or on any better way of sending mail.

__________________
-.. -..
 
Old April 26th, 2004, 09:07 PM
Authorized User
 
Join Date: Jan 2004
Posts: 16
Thanks: 0
Thanked 0 Times in 0 Posts
Default

         mailMessage.From = strfrom
                 mailMessage.To = strTo
                 mailMessage.Subject = strSubject

                 mailMessage.Body = strComments
                 mailMessage.BodyFormat = System.Web.Mail.MailFormat.Html

                ' TODO: Set the mailMessage.Body property
System.Web.Mail.SmtpMail.SmtpServer = "YourSMTPSERVER"
                 System.Web.Mail.SmtpMail.Send(mailMessage)






Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem In Sending mails deepak0511 Pro JSP 0 December 11th, 2006 04:06 AM
sending e-mails How To?? saudyonline General .NET 13 November 17th, 2006 01:00 AM
sending mails arabuafef Classic ASP Basics 0 July 18th, 2006 06:29 AM
Sending mails. rupen Javascript How-To 1 October 25th, 2005 07:22 AM
Sending mails rajeshnerenki Pro VB 6 4 September 25th, 2003 03:34 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.