p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 (http://p2p.wrox.com/forumdisplay.php?f=252)
-   -   Chapter 1 (http://p2p.wrox.com/showthread.php?t=51493)

cityside December 13th, 2006 08:52 AM

Chapter 1
 
I have followed the installation instructions on pp 34-35.
Browsing to SignOn.aspx and registering a new user asks for a user name and password etc. It seems that whatever password I use the response states that the password must be 7 characters minimum.

I tried the forgoten your password option and gave a random user name. The following error message appeared:

Cannot open user default database. Login failed.
Login failed for user 'CWHSS15\ASPNET'.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException: Cannot open user default database. Login failed.
Login failed for user 'CWHSS15\ASPNET'.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[SqlException (0x80131904): Cannot open user default database. Login failed.
Login failed for user 'CWHSS15\ASPNET'.]
   System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException exception, Boolean breakConnection) +734963
   System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject stateObj) +188
   System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +1838
   System.Data.SqlClient.SqlInternalConnectionTds.Com pleteLogin(Boolean enlistOK) +33
   System.Data.SqlClient.SqlInternalConnectionTds.Ope nLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +628
   System.Data.SqlClient.SqlInternalConnectionTds..ct or(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +170
   System.Data.SqlClient.SqlConnectionFactory.CreateC onnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +359
   System.Data.ProviderBase.DbConnectionFactory.Creat ePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +28
   System.Data.ProviderBase.DbConnectionPool.CreateOb ject(DbConnection owningObject) +424
   System.Data.ProviderBase.DbConnectionPool.UserCrea teRequest(DbConnection owningObject) +66
   System.Data.ProviderBase.DbConnectionPool.GetConne ction(DbConnection owningObject) +496
   System.Data.ProviderBase.DbConnectionFactory.GetCo nnection(DbConnection owningConnection) +82
   System.Data.ProviderBase.DbConnectionClosed.OpenCo nnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +105
   System.Data.SqlClient.SqlConnection.Open() +111
   System.Web.DataAccess.SqlConnectionHolder.Open(Htt pContext context, Boolean revertImpersonate) +84
   System.Web.DataAccess.SqlConnectionHelper.GetConne ction(String connectionString, Boolean revertImpersonation) +197
   System.Web.Security.SqlMembershipProvider.GetUser( String username, Boolean userIsOnline) +1491
   System.Web.Security.MembershipProvider.GetUser(Str ing username, Boolean userIsOnline, Boolean throwOnError) +31
   System.Web.UI.WebControls.PasswordRecovery.Attempt SendPasswordUserNameView() +90
   System.Web.UI.WebControls.PasswordRecovery.Attempt SendPassword() +52
   System.Web.UI.WebControls.PasswordRecovery.OnBubbl eEvent(Object source, EventArgs e) +101
   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35
   System.Web.UI.WebControls.Button.OnCommand(Command EventArgs e) +115
   System.Web.UI.WebControls.Button.RaisePostBackEven t(String eventArgument) +163
   System.Web.UI.WebControls.Button.System.Web.UI.IPo stBackEventHandler.RaisePostBackEvent(String eventArgument) +7
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler sourceControl, String eventArgument) +11
   System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +33
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102


Imar December 13th, 2006 02:21 PM

Hi there,

Did you grant read/write permissions to the App_Data folder for the ASPNET account?

Page 164 - 165 explain how to do this in more detail.

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.

cityside December 15th, 2006 06:19 AM

Yes thanks. I've already solved it. Apparently it concerns the order in which IIS and .NET were installed. The ASP.NET account wasn't registered. For others who come accross this problem, try running this solution from the Microsoft Knowledge Base, from the DOS prompt:

"%windir%\Microsoft.NET\Framework\v2.0.50727\aspne t_regiis.exe" -i

Love the book BTW.



Imar December 15th, 2006 09:20 AM

Glad it's working now......
Quote:

quote:Love the book BTW.
Spread the word, spread the word!!! ;)

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.


All times are GMT -4. The time now is 08:24 PM.

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