Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3
This is the forum to discuss the Wrox book Beginning ASP.NET 3.5: In C# and VB by Imar Spaanjaars; ISBN: 9780470187593
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old August 12th, 2011, 12:01 PM
Authorized User
Points: 45, Level: 1
Points: 45, Level: 1 Points: 45, Level: 1 Points: 45, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jul 2011
Posts: 11
Thanks: 2
Thanked 0 Times in 0 Posts
Default chapter 15: WSAT error

when I try to enter the Web Site Administration Tool (Website > ASP.NET Configuration), I get this message:
Quote:
An error was encountered. Please return to the previous page and try again.
how do I solve this problem?
Reply With Quote
  #2 (permalink)  
Old August 12th, 2011, 03:17 PM
Imar's Avatar
Wrox Author
Points: 72,038, Level: 100
Points: 72,038, Level: 100 Points: 72,038, Level: 100 Points: 72,038, Level: 100
Activity: 50%
Activity: 50% Activity: 50% Activity: 50%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,080
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi there,

Maybe your database isn't setup correctly? Do other features such as membership work at the frontend? Can you post the code for your web.config?

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
  #3 (permalink)  
Old August 12th, 2011, 03:58 PM
Authorized User
Points: 45, Level: 1
Points: 45, Level: 1 Points: 45, Level: 1 Points: 45, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jul 2011
Posts: 11
Thanks: 2
Thanked 0 Times in 0 Posts
Default

here is a screenshot:
http://img37.imageshack.us/img37/2577/unledldh.png

and here is the web.config:
Code:
<?xml version="1.0"?>
<!-- 
    Note: As an alternative to hand editing this file you can use the 
    web admin tool to configure settings for your application. Use
    the Website->Asp.Net Configuration option in Visual Studio.
    A full list of settings and comments can be found in 
    machine.config.comments usually located in 
    \Windows\Microsoft.Net\Framework\v2.x\Config 
-->
<configuration>
  <appSettings/>
  <connectionStrings>
    <add name="PlanetWroxConnectionString1" connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\PlanetWrox.mdf;Integrated Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
  </connectionStrings>
  <system.web>
    <!-- 
            Set compilation debug="true" to insert debugging 
            symbols into the compiled page. Because this 
            affects performance, set this value to true only 
            during development.
        -->
    <compilation debug="true" targetFramework="4.0">
      <assemblies>
        <add assembly="System.Web.DynamicData, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        <add assembly="System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
        <add assembly="System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
        <add assembly="System.ComponentModel.DataAnnotations, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        <add assembly="System.Data.Linq, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
        <add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
        <add assembly="System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
        <add assembly="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
        <add assembly="System.Web.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
        <add assembly="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
      </assemblies>
    </compilation>
    <!--
            The <authentication> section enables configuration 
            of the security authentication mode used by 
            ASP.NET to identify an incoming user. 
        -->
      <membership>
          <providers>
              <clear/>
              <add name="AspNetSqlMembershipProvider" 
                   type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" 
                   connectionStringName="LocalSqlServer" 
                   enablePasswordRetrieval="false" 
                   enablePasswordReset="true" 
                   requiresQuestionAndAnswer="false" 
                   applicationName="/" 
                   requiresUniqueEmail="false" 
                   passwordFormat="Hashed" 
                   maxInvalidPasswordAttempts="5" 
                   minRequiredPasswordLength="6" 
                   minRequiredNonalphanumericCharacters="0" 
                   passwordAttemptWindow="10" 
                   passwordStrengthRegularExpression=""/>
          </providers>
      </membership>
      
      <authentication mode="Forms">
          <forms timeout="43200" />
      </authentication>
    <!--
            The <customErrors> section enables configuration 
            of what to do if/when an unhandled error occurs 
            during the execution of a request. Specifically, 
            it enables developers to configure html error pages 
            to be displayed in place of a error stack trace.

        <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
            <error statusCode="403" redirect="NoAccess.htm" />
            <error statusCode="404" redirect="FileNotFound.htm" />
        </customErrors>
        -->
    <pages theme="Monochrome" controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID">
      <controls>
        <add tagPrefix="Wrox" tagName="Banner" src="~/Controls/Banner.ascx"/>
      </controls>
    </pages>
  </system.web>
  <!-- 
  The system.webServer section is required for running ASP.NET AJAX under Internet
  Information Services 7.0.  It is not necessary for previous version of IIS.
  -->
  <system.net>
    <mailSettings>
      <smtp deliveryMethod="Network" from="Planet Wrox System &lt;vaindru@yahoo.Com&gt;">
        <network host="smtp.mail.yahoo.com" userName="******" password="**********"/>
      </smtp>
    </mailSettings>
  </system.net>
</configuration>
Reply With Quote
  #4 (permalink)  
Old August 13th, 2011, 03:38 AM
Imar's Avatar
Wrox Author
Points: 72,038, Level: 100
Points: 72,038, Level: 100 Points: 72,038, Level: 100 Points: 72,038, Level: 100
Activity: 50%
Activity: 50% Activity: 50% Activity: 50%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,080
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hmmm, not sure what's going on. Do you have the aspnetb.mdf file in your App_Data folder? Does Membership work at the frontend?

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
  #5 (permalink)  
Old August 13th, 2011, 03:48 AM
Authorized User
Points: 45, Level: 1
Points: 45, Level: 1 Points: 45, Level: 1 Points: 45, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jul 2011
Posts: 11
Thanks: 2
Thanked 0 Times in 0 Posts
Default

I have ASPNETDB.mdf file in the App_Data, and what frontend? if you mean the WSAT frontend then no, the screenshot i posted is all I get.
I know just that the sign up and login are working...

Last edited by dany96; August 13th, 2011 at 03:51 AM..
Reply With Quote
  #6 (permalink)  
Old August 13th, 2011, 06:36 AM
Imar's Avatar
Wrox Author
Points: 72,038, Level: 100
Points: 72,038, Level: 100 Points: 72,038, Level: 100 Points: 72,038, Level: 100
Activity: 50%
Activity: 50% Activity: 50% Activity: 50%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,080
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Quote:
I know just that the sign up and login are working...
Yeah, that's what I meant with frontend. This indicates that Membership works as expected and is configured correctly in the web.config.

You may want to search Google for the exact error message and see if that brings up something useful. The error has been reported by others and one of their solutions may help.

Can you verify your own account has permissions to write to the App_Data folder? To see if it's a security problem, try granting Full Control to the Everyone account temporarily.

Cheers,

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
  #7 (permalink)  
Old August 13th, 2011, 06:37 AM
Imar's Avatar
Wrox Author
Points: 72,038, Level: 100
Points: 72,038, Level: 100 Points: 72,038, Level: 100 Points: 72,038, Level: 100
Activity: 50%
Activity: 50% Activity: 50% Activity: 50%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,080
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Another thing to check: what's the path to your web site on your disk?

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
  #8 (permalink)  
Old August 13th, 2011, 08:13 AM
Authorized User
Points: 45, Level: 1
Points: 45, Level: 1 Points: 45, Level: 1 Points: 45, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jul 2011
Posts: 11
Thanks: 2
Thanked 0 Times in 0 Posts
Default

C:\Users\VaindrU\Documents\C#WEB\Site
Reply With Quote
  #9 (permalink)  
Old August 13th, 2011, 08:28 AM
Imar's Avatar
Wrox Author
Points: 72,038, Level: 100
Points: 72,038, Level: 100 Points: 72,038, Level: 100 Points: 72,038, Level: 100
Activity: 50%
Activity: 50% Activity: 50% Activity: 50%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,080
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Ah, that's what I thought (not the exact path, but the # in the folder name). Try this:

1. Close Visual Studio
2. Rename the folder by removing the # or rename it to something like C:\Users\VaindrU\Documents\CSharpWEB\Site
3. Open the web site from its new location in VWD.
4. Try the WSAT again.

I think it should work then.

IMO, you're usually better off placing sites in a folder outside your Documents folder such as C:\Websites. Your Documents folder has special permissions applied which may cause security problems. That's not the reason for the current problem, but you may run in to it in the future.

Cheers,

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
The Following User Says Thank You to Imar For This Useful Post:
dany96 (August 13th, 2011)
  #10 (permalink)  
Old August 13th, 2011, 01:21 PM
Authorized User
Points: 45, Level: 1
Points: 45, Level: 1 Points: 45, Level: 1 Points: 45, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jul 2011
Posts: 11
Thanks: 2
Thanked 0 Times in 0 Posts
Default

Thanks man! it works now.
btw I enjoyed your book, I almost finished it and I already built a simple website for a friend and uploaded it on the internet.
and I wanted to ask you what to learn after this book, is there some advanced things in asp.net that u recomend to learn? I know that u published another one asp.net 4, but I saw that the only new thing there I think is the JQuery..
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 15 WSAT areed24 BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 1 March 13th, 2009 04:21 PM
Chapter 15: WSAT doesn't show up RobRob BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 4 September 27th, 2008 06:42 AM
error while debugging in chapter 15 great.early805 BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 1 April 12th, 2008 02:27 AM
Chapter 15 Code Error - HELP! peterjstorey BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 5 January 24th, 2008 05:33 PM
Chapter 15 page 662 error lance BOOK: Beginning ASP 3.0 0 February 12th, 2004 08:56 PM



All times are GMT -4. The time now is 07:20 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.