Wrox Programmer Forums
|
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
 
Old March 21st, 2006, 04:14 PM
Registered User
 
Join Date: Mar 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default CMS

I installed the CMS on IIS and got this error message.
Does anybody have any ideas so I can regain my sanity.

Thanks

Easter

Server Error in '/Cms' Application.
--------------------------------------------------------------------------------

Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Unrecognized attribute 'xmlns'.

Source Error:


Line 8: \Windows\Microsoft.Net\Framework\v2.x\Config
Line 9: -->
Line 10: <configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
Line 11: <appSettings>
Line 12: <add key="FCKeditor:UserFilesPath" value="/Cms/UserFiles"/>


Source File: C:\inetpub\wwwroot\Cms\web.config Line: 10


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


eddie
 
Old March 21st, 2006, 11:03 PM
Authorized User
 
Join Date: Mar 2006
Posts: 53
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Dear Friend,

I can understand that you are using Framework 1.1 for the cms, while the books is already for asp.net 2.0 as mentioned in title itself.

Pl. remove the framework 1.1, backup all your details to a safe place, and install 2.0.

now run the code again, it will work.

Hope this helps

SoftMind
 
Old March 22nd, 2006, 12:49 PM
Registered User
 
Join Date: Mar 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Soft mind,

I had both Net Framework 1 and 2 on my PC but I have done as you say and now a new error message has appeared. I have the MSDE engine on my PC not SQL Server 2005. I tried to register aspnet_regiis.exe as before but this time my PC will not accept it. Do you have an explanation for this new error. There are no instructions I can find.

Thanks:)

Bye now,

Easter

Server Error in '/Cms' Application.
--------------------------------------------------------------------------------

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
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 error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

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): An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)]
   System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException exception, Boolean breakConnection) +735171
   System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject stateObj) +188
   System.Data.SqlClient.TdsParser.Connect(Boolean& useFailoverPartner, Boolean& failoverDemandDone, String host, String failoverPartner, String protocol, SqlInternalConnectionTds connHandler, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection owningObject, Boolean aliasLookup) +820
   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) +130
   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.Data.Common.DbDataAdapter.FillInternal(Data Set dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +121
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +137
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String srcTable) +83
   System.Web.UI.WebControls.SqlDataSourceView.Execut eSelect(DataSourceSelectArguments arguments) +1770
   System.Web.UI.WebControls.Repeater.GetData() +50
   System.Web.UI.WebControls.Repeater.CreateControlHi erarchy(Boolean useDataSource) +232
   System.Web.UI.WebControls.Repeater.OnDataBinding(E ventArgs e) +53
   System.Web.UI.WebControls.Repeater.DataBind() +72
   System.Web.UI.WebControls.Repeater.EnsureDataBound () +55
   System.Web.UI.WebControls.Repeater.OnPreRender(Eve ntArgs e) +12
   System.Web.UI.Control.PreRenderRecursiveInternal() +77
   System.Web.UI.Control.PreRenderRecursiveInternal() +161
   System.Web.UI.Control.PreRenderRecursiveInternal() +161
   System.Web.UI.Control.PreRenderRecursiveInternal() +161
   System.Web.UI.Control.PreRenderRecursiveInternal() +161
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1360




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

eddie
 
Old March 22nd, 2006, 02:03 PM
Authorized User
 
Join Date: Feb 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to Shawn Livermore Send a message via Yahoo to Shawn Livermore
Default

I believe you would need SQL Server 2005 (express works too).

Thanks,

Shawn
shawnlivermore.blogspot.com
 
Old March 22nd, 2006, 02:40 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Easter,

Shawn is correct; most applications in the book work with SQL Server 2005.

Is there a reason you didn't install SQL Server 2005 Express Edition? It's free, just like the MSDE and it makes developing applications a lot easier. And, because the book uses 2005 exclusively, it'll be easier to follow along with the book.

HtH,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
While typing this post, I was listening to: I Miss You by Björk (Track 9 from the album: Post) What's This?
 
Old May 28th, 2006, 07:16 PM
Registered User
 
Join Date: May 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Good day,

I started with the CMS project today, and had most of the problems listed in the forum:

I created a directory on my PC , and made this a virtual directory of localhost. I have .NET frameworks 1 and 2 running side by side, so I changed the virtual directory properties to use .NET 2 I then installed the CMS using the installer into that directory,

I had SQL Server 2000 installed and that gave errors attaching to the database. I dumped that and installed SQL Server Express 2005, with SQL Server Management Studio Express. I could not attach the CMS database.

 
Quote:
quote:An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)]


In SQL Server 2005 > Configuration Tools > SQL Server Configuration Manager >SQL Server Network Configuration > Protocols for SQLExpress I enabled all the disabled protocols, and was able to connect using Integrated Windows Authentication, but not SQL Server Authentication.

Running the CMS I got the error that the database could not be opened - caused by the fact that the ASP.NET user did not have security permissions on the App_data directory (RTFM pages 163 and 164)

Then the CMS started to work but I could not log in. I followed Inmar's instructions elsewhere in the forum to the letter using the Website Admin Tool to add the Administrator to the Administrator role. That fixed the log-in problem.

Then I clicked on /Management/ContentList.aspx, and got a strange error, the page was unable to refer to its partial class in the aspx.vb file. Checking both files in Visual Studio everything appeared OK, but the I saw that there was another ContentList.aspx in the site root. I wondered whetehr the application was getting confused with its partial class references, so in /Management/ContentList.aspx I changed the Inherits="ContentList" to Inherits="ManagementContentList", and changed the name of the partial class in the aspx.vb file which fixed the problem there, and I haven't found any problems elsewhere that may have been caused by that change. Perhaps someone could comment on wheter my surmise is correct.

The reactions of the authors to problems are exemplary. I'm mighty impressed with what I've seen so far, it all proves how true my signature is....

Gixxer
The more I learn the more I realise how little I know

 
Old May 29th, 2006, 02:33 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Gixxer,

I have seen the error you got related to the partial class ContentList once or twice. Funny thing is, I have successfully built sites that have many pages with the same name and code behind class (Default.aspx being a good example). So, I am not exactly sure why that error occurs.

Your solution is a good way to prevent the problem. Another solution is to give each code behind class a unique namespace based on the folder the page is located in. E.g.:
Code:
Namespace Wrox.Cms.Web

End Namespace
for pages in the root and
Code:
Namespace Wrox.Cms.Web.Management

End Namespace
for pages in the Management folder. That way, each class lives in a unique scope.

The databases that come with the book are for SQL Server 2005 only; so there's no way to attach them to a SQL Server 2000 instance. You already found that out, but I just wanted to confirm it.

With regards to the CMS Login: this is indeed a problem when you run the application under IIS through http://localhost/Cms. In an earlier post I described the steps to fix that manually. I also created an updated version of the database that you can download, in case you need it. More details can be found here: http://p2p.wrox.com/topic.asp?TOPIC_...98&whichpage=2

Good luck with the CMS application. Hope you like it and you know where to come to when you have other questions / problems.....

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
 
Old May 29th, 2006, 05:27 AM
Registered User
 
Join Date: May 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Imar,

Thanks for the reply regarding namespace naming.

Visual Web Developer 2005 Express automatically includes the directory as part of the generated reference in the main aspx file and the corresponding code behind file.

This leads me to conclude that Microsoft must have seen that this problem can occur.

Regards
Gixxer


The more I learn the more I realise how little I know
 
Old May 29th, 2006, 02:02 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Yeah, true, it does that, and apparently for a reason.

Personally, I am not too happy with it, as you can end up with very long class names, for files deeply nested in a folder structure. I prefer to use namespaces instead.

Still it's odd that error doesn't happen all the time. Or, in fact, it's odd the error happens every now and then. Each folder should compile to a separate assembly, so there should be no naming conflicts.

Oh well, as long as it works with your fix.

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
 
Old August 6th, 2006, 05:50 PM
Authorized User
 
Join Date: Aug 2006
Posts: 42
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to abel714 Send a message via Yahoo to abel714
Default

I am having the same problem as above, right after installing the code files from the book.

I have read over the replies, but don't see any reply that implies that a conclusion has been drawn with this issue.

I set everything up verbatim as stated in the book, turned my firewall and everything else off, and nothing seems to evade these error messages.

Has anyone found out what is causing these messages?

I thought this code was supposed to work, right out of the box.

I have everything setup as instructed, but seem to keep running into these error messages. Is there something in the ASP.NET config that causes this? Please advise.

Thank you in advance.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Wrox CMS retroviz BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 5 January 31st, 2007 01:23 PM
CMS abaso.jadhav01 ASP.NET 2.0 Basics 3 November 22nd, 2006 02:47 AM
CMS-Cant Login SoftMind BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 42 August 10th, 2006 03:23 PM
CMS Automation zubo01 XML 6 June 6th, 2006 09:05 AM
CMS anshul Pro PHP 2 May 30th, 2005 01:22 AM





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