Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8
This is the forum to discuss the Wrox book Beginning ASP.NET 2.0 by Chris Hart, John Kauffman, David Sussman, Chris Ullman; ISBN: 9780764588501
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 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 July 14th, 2006, 10:03 AM
Registered User
 
Join Date: Jul 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Server Error in '/WroxUnited' Application

I've been trying for several days to get the WroxUnited application to work with IIS5.1 - it works under Cassini

I'm running XP Pro with SP2, vwd and sql express. Whatever I try, I get the following error message:

-----------------------------------------------------------------
An attempt to attach an auto-named database for file C:\Inetpub\wwwroot\WroxUnited\App_Data\aspnetdb.md f failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.
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: An attempt to attach an auto-named database for file C:\Inetpub\wwwroot\WroxUnited\App_Data\aspnetdb.md f failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.

Source Error:

Line 112: Public Overridable Property Theme() As String
Line 113: Get
Line 114: Return CType(Me.GetPropertyValue("Theme"),String)
Line 115: End Get
Line 116: Set


Source File: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temp orary ASP.NET Files\wroxunited\80802c5c\69674225\App_Code.hikway lb.6.vb Line: 114

Stack Trace:

[SqlException (0x80131904): An attempt to attach an auto-named database for file C:\Inetpub\wwwroot\WroxUnited\App_Data\aspnetdb.md f failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.]
   System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException exception, Boolean breakConnection) +735043
   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.Profile.SqlProfileProvider.GetPropertyV aluesFromDatabase(String userName, SettingsPropertyValueCollection svc) +766
   System.Web.Profile.SqlProfileProvider.GetPropertyV alues(SettingsContext sc, SettingsPropertyCollection properties) +428
   System.Configuration.SettingsBase.GetPropertiesFro mProvider(SettingsProvider provider) +410
   System.Configuration.SettingsBase.GetPropertyValue ByName(String propertyName) +117
   System.Configuration.SettingsBase.get_Item(String propertyName) +89
   System.Web.Profile.ProfileBase.GetInternal(String propertyName) +36
   System.Web.Profile.ProfileBase.get_Item(String propertyName) +68
   System.Web.Profile.ProfileBase.GetPropertyValue(St ring propertyName) +4
   ProfileCommon.get_Theme() in C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temp orary ASP.NET Files\wroxunited\80802c5c\69674225\App_Code.hikway lb.6.vb:114
   Wrox.Web.GlobalEvents.ThemeModule.app_PreRequestHa ndlerExecute(Object Sender, EventArgs E) in C:\Inetpub\wwwroot\WroxUnited\App_Code\ThemeModule .vb:30
   System.Web.SyncEventExecutionStep.System.Web.HttpA pplication.IExecutionStep.Execute() +92
   System.Web.HttpApplication.ExecuteStep(IExecutionS tep step, Boolean& completedSynchronously) +64

Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42
-------------------------------------------------------------------

The database folder is not shared, and writing is enabled.
Sql express was set as a network service, but I changed it to local.
I've also tried 'aspnet_regiis.exe -i with no success.

Can anyone suggest what else I should check?
 
Old July 15th, 2006, 02:58 PM
Registered User
 
Join Date: Jul 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Anyone ?
 
Old July 16th, 2006, 05:06 AM
Registered User
 
Join Date: Jul 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi steall,

I have the Wrox website working under IIS 5.1 -- but I also had a devil of a time with it.

I got the same database error as you describe -- unfortunately, I tried so many things to get it working -- that I'm not sure which one did the trick.

I know one of the biggest headaches was discovering that I couldn't have the database open in SQL Server Management Studio (I have SQL 2005 & SQL Express both installed) while trying to run the web site. Beyond that -- I'm a complete newb. sorry.

If you'd like me to check any settings and the like I'd be happy to do that.

-bruce
 
Old July 31st, 2006, 01:54 PM
Friend of Wrox
 
Join Date: Jul 2006
Posts: 238
Thanks: 0
Thanked 2 Times in 2 Posts
Send a message via MSN to rsearing
Default

Bruce...is there a way to contact you? I am a complete newb myself..had a free copy of sql server 2005 and visual studio 2005 through school (UMKC) and haven't completed the book--but was working on the login stuff. Worked fine inside visual studio..but when I try to put it in IIS...I have all sorts of config. problems with Sql server. Alot of it is not realizing what I am doing or doing something but not realizing why it works.

Alot comes from not understanding how asp.net interacts with the aspnetdb.mdf file.

Kind Regards,
Rob Searing






Similar Threads
Thread Thread Starter Forum Replies Last Post
IIS - Server Error in '/WroxUnited' Application lukemack BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 2 July 18th, 2006 11:23 AM
Server Error in '/WroxUnited' Application ermutigen BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 3 April 28th, 2006 12:07 PM
Server Application Error cis BOOK: Beginning ASP.NET 1.0 2 February 12th, 2004 06:55 PM





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