 |
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6
 | This is the forum to discuss the Wrox book ASP.NET 2.0 Instant Results by Imar Spaanjaars, Paul Wilton, Shawn Livermore; ISBN: 9780471749516 |
|
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 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
|
|
|
|
|

April 19th, 2006, 06:37 PM
|
|
Authorized User
|
|
Join Date: Apr 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Survey Engine - Does not work
Hi,
When I submitted the survey, I got the following error
Failed to update database "C:\INETPUB\WWWROOT\SURVEYENGINE\APP_DATA\SURVEYDB .MDF" because the database is read-only.
when i tried to login as Admin or SuperAdmin with password# I get the following error:
Server Error in '/SurveyEngine' Application.
--------------------------------------------------------------------------------
Index was outside the bounds of the array.
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.IndexOutOfRangeException: Index was outside the bounds of the array.
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:
[IndexOutOfRangeException: Index was outside the bounds of the array.]
System.Data.SqlClient.SqlDataReader.ReadColumn(Int 32 i, Boolean setTimeout) +808741
System.Data.SqlClient.SqlDataReader.GetDateTime(In t32 i) +21
System.Web.Security.SqlMembershipProvider.GetPassw ordWithFormat(String username, Boolean updateLastLoginActivityDate, Int32& status, String& password, Int32& passwordFormat, String& passwordSalt, Int32& failedPasswordAttemptCount, Int32& failedPasswordAnswerAttemptCount, Boolean& isApproved, DateTime& lastLoginDate, DateTime& lastActivityDate) +1121
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username, String password, Boolean updateLastLoginActivityDate, Boolean failIfNotApproved, String& salt, Int32& passwordFormat) +105
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username, String password, Boolean updateLastLoginActivityDate, Boolean failIfNotApproved) +42
System.Web.Security.SqlMembershipProvider.Validate User(String username, String password) +83
System.Web.UI.WebControls.Login.OnAuthenticate(Aut henticateEventArgs e) +160
System.Web.UI.WebControls.Login.AttemptLogin() +105
System.Web.UI.WebControls.Login.OnBubbleEvent(Obje ct source, EventArgs e) +99
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
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42
|
|

April 20th, 2006, 01:58 PM
|
|
Authorized User
|
|
Join Date: Feb 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Sometimes the .mdf database file becomes read only. Right click that file, properties, uncheck the read only status, and click apply. Try it again?
Thanks,
Shawn Livermore
MCAD, MCSD, PMP
http://www.shawnlivermore.blogspot.com
|
|

April 24th, 2006, 12:47 PM
|
|
Authorized User
|
|
Join Date: Apr 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
I checked the .mdf file is not read only
|
|

April 24th, 2006, 01:23 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
There might be an issue with the aspnetdb.mdf file. You may want to try the following:
1. Delete the ASPNETDB database from the App_Data folder (both the MDF and LDF files)
2. Try to login in. This will fail, but a new ASPNETDB database will be created automatically in the App_Data folder.
3. Run the Website Administration Tool and create a new user called Admin (choose your own password) and a new Role called Admin.
4. Assign the new user to the Admin role.
5. Log in.
I think this should work; I know it worked for me....
Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
|
|

April 25th, 2006, 06:14 PM
|
|
Authorized User
|
|
Join Date: Feb 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
I don't understand why we would have to delete the aspnetdb, but it worked!
|
|

April 25th, 2006, 06:35 PM
|
|
Authorized User
|
|
Join Date: Feb 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
I was also getting an error when I used it through IIS. It was on the AppCode/Dal/SurveyDB. vb class. The line 99 throw was creating an error. I haven't read the section yet, so it was probably my mistake.
|
|

April 26th, 2006, 01:15 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
I think there's an issue with one of the stored procedures in the aspnetdb.mdf file that comes with the book.
When you delete the database file, .NET will automatically create a new one, based on a template on your local machine. This template database contains the correct procedures (developed by Microsoft for the ASP.NET features like Membership and Role manager) so your database ends up with the right versions as well.
HtH,
Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
While typing this post, I was listening to: Trilogy by Sonic Youth (Track 12 from the album: Daydream Nation) What's This?
|
|

June 4th, 2007, 12:26 PM
|
|
Registered User
|
|
Join Date: Aug 2003
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Quote:
quote:Originally posted by Imar
There might be an issue with the aspnetdb.mdf file. You may want to try the following:
1. Delete the ASPNETDB database from the App_Data folder (both the MDF and LDF files)
2. Try to login in. This will fail, but a new ASPNETDB database will be created automatically in the App_Data folder.
3. Run the Website Administration Tool and create a new user called Admin (choose your own password) and a new Role called Admin.
4. Assign the new user to the Admin role.
5. Log in.
I think this should work; I know it worked for me....
Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
|
|
|

June 4th, 2007, 12:29 PM
|
|
Registered User
|
|
Join Date: Aug 2003
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Okay... how do you "Website Administration Tool" to create new Admin Account???
BTW... I already have a aspnetdb and log file setup in SQL2005 Express. I cannot log in at all.
|
Similar Threads
|
| Thread |
Thread Starter |
Forum |
Replies |
Last Post |
| Survey Engine |
Dennis239 |
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 |
6 |
March 3rd, 2008 02:34 PM |
| Survey Engine |
anitafn2005 |
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 |
5 |
February 18th, 2007 01:56 AM |
| Survey engine |
anitafn2005 |
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 |
13 |
February 11th, 2007 04:49 PM |
| Survey engine |
anitafn2005 |
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 |
1 |
October 8th, 2006 04:17 PM |
| Wrox Survey Engine |
Berggreen |
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 |
7 |
June 25th, 2006 05:21 PM |
|
 |