Wrox Programmer Forums
|
BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0
This is the forum to discuss the Wrox book ASP.NET 2.0 Website Programming: Problem - Design - Solution by Marco Bellinaso; ISBN: 9780764584640
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 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 August 30th, 2007, 04:04 PM
rav rav is offline
Authorized User
 
Join Date: Feb 2007
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default Error: Capter 3 in ASP.Net 2.0 web prog

Hello:
I am newbie and now compleated reading chapter 3 of asp.net 2.0 web programming problem-design-solution.
I am doing with C#.
Not able to send eamil message with contract.aspx page.
I am running the site in my localhost. I am trying to send email to myself and doing the following in web.config file. It shows the label message that my email is sent, but i did not receive it in my yahoo email. Why is that???

<system.net>
<mailSettings>
<smtp deliveryMethod="PickupDirectoryFromIis" from="r [email protected]">
    <network defaultCredentials="true" host="(localhost)" port="25"/>
</smtp>
</mailSettings>
</system.net>

Also, I tried setting up smtp deliveryMethod="Network" , then my error label shows that unable sending message...
I will appreciate your help.
Thank you
 
Old August 30th, 2007, 04:50 PM
Authorized User
 
Join Date: Mar 2007
Posts: 39
Thanks: 0
Thanked 1 Time in 1 Post
Default

You need to have Internet Information Services (IIS) running on your local machine, with SMTP enabled in order to send mail.

Here is link to IIS site:
http://www.iis.net/default.aspx?tabid=1

 
Old August 31st, 2007, 01:40 PM
rav rav is offline
Authorized User
 
Join Date: Feb 2007
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you
I am running IIS 5.1 and i have now enabled SMTP and allowed my computer to relay through this virtual server. Still when I run my application I get the Exception: ((System.Net.Mail.SmtpException)(ex))={"Failure sending mail."}
ex._innerException._message ="The remote name could not be resolved: '(localhost)'" "

I am not able to send eamil to myself from contact page..

I am specifying the following in web.config
<TheWebHouse defaultConnectionStringName="LocalSqlServer">
        <contactForm mailTo="[email protected]"/>
    </TheWebHouse>

<smtp deliveryMethod="Network" >
<network defaultCredentials="true" host="(localhost)" port="25"/>
            </smtp>


Why do I get this message??? Is it bec. I am not running MSSQL?? I closed MSSQL from computer management and now not able to start up agian..
Need Your help.
Thx


 
Old August 31st, 2007, 03:42 PM
Authorized User
 
Join Date: Mar 2007
Posts: 39
Thanks: 0
Thanked 1 Time in 1 Post
Default

Try host="localhost"

Also, SQL has nothing to do with SMTP server, so that is not your problem.

 
Old August 31st, 2007, 04:58 PM
rav rav is offline
Authorized User
 
Join Date: Feb 2007
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I did as you said and this time I get a different error..

{"Mailbox unavailable. The server response was: 5.7.1 Unable to relay for [email protected]"}
Why do I get this error?? I have this email address that I just checked...
waiting for reply
thx

 
Old August 31st, 2007, 06:31 PM
Friend of Wrox
 
Join Date: Mar 2006
Posts: 310
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Are you trying to send email messages from your local machine?

If so... Not every email accounts allow that!

If you can, try to use some gmail account!

 
Old September 1st, 2007, 11:44 AM
rav rav is offline
Authorized User
 
Join Date: Feb 2007
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you
I tried Gmail account too and still get the errors...
Anyways, I will wait to fix this error untill I get a web hosting...I will check it later after I host it...
Now, my another problem is when I am doing health management code of chapter 3 where it asks for creating custom events in seperate asembly then the solution... How to do it?? How to create a seperate solution for main code??
I tried adding new solution and then deleted default form, added cs file named CustomEvents.cs with the code given in chapter 3, then Build the solution... I get an error saying starting Main is not found...HOw to fix it??
Am I doing it correct?? Is there any other method of doing it?
waiting for your reply..
Thanks


 
Old September 2nd, 2007, 08:18 AM
Friend of Wrox
 
Join Date: Sep 2003
Posts: 143
Thanks: 0
Thanked 1 Time in 1 Post
Default

rav, concerning your second question, I asnwered you here:

http://p2p.wrox.com/topic.asp?TOPIC_ID=64591

 
Old September 3rd, 2007, 02:56 PM
Friend of Wrox
 
Join Date: Sep 2003
Posts: 143
Thanks: 0
Thanked 1 Time in 1 Post
Default

rav,

I had the same problem as you. Managed to solve it this night.

Check my blog for a post that might help you out :)

Cheers,

Peter

http://entropia-online.blogspot.com/
 
Old September 5th, 2007, 07:51 PM
rav rav is offline
Authorized User
 
Join Date: Feb 2007
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks all
I am finally not getting any errors sending email...but still I don't receieve the eamil that I am sending via contact page.. I tried sending to both yahoo and gmail accounts... I have also set Relay Access of SMTP in IIS for 127.0.1........
I don't know why...If any other suggestions to fix this problem then please let me know..
As I said I will wait to upload the site on the hosting server and then check if I am able to receive eamil from contact page...
Thanks..






Similar Threads
Thread Thread Starter Forum Replies Last Post
ASP.NET E-Commerce Prog Problem - Design - gapoce All Other Wrox Books 42 February 9th, 2011 03:06 AM
Difference between ASP.NET programmer v/s C# prog myquery General .NET 1 October 20th, 2007 06:43 AM
ERROR using ASP.net Web Site Administration Tool erictamlam ASP.NET 2.0 Basics 0 April 5th, 2007 02:52 AM
ERROR using ASP.net Web Site Administration Tool erictamlam C# 2005 0 April 3rd, 2007 01:28 AM
ASP.NET E-Commerce Prog Problem - Design -Solution cat2123 All Other Wrox Books 1 December 29th, 2003 06:27 AM





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