Upgrades Questions on upgrading to version 7.x.
Version 7.x > Upgrades > Error on Root page and properties tab View modes: 
User avatar
Member
Member
beau.cowan-rrpartners - 2/11/2013 12:27:49 PM
   
Error on Root page and properties tab
I have 2 errors going on since trying my upgrade to 7 on my localhost. I'm not sure if the 2 are related to one another, but I'm hoping that if I solve one the other will become resolved as well.


Problem 1:
Parser Error Message: Could not load type 'CMSModules_Content_CMSDesk_Properties_General'.

We have an application variable that we added to this file in 6 to help with a dynamic header generation, having the CMS know when to restructure the header on clearing output cache or when a sync has been done. I removed our code from this, and it is still giving this error. The namespace seems to be the same as what's in the ASPX file, so I'm unclear why the system would not be able to find this.


Problem 2 (Major):
The control collection cannot be modified during DataBind, Init, Load, PreRender or Unload phases.

This one affects all display pages, both preview and live. I'm unsure what is causing this, and have taken out all unnecessary web parts and CMS items from the Root.Master and the code behind. I even tried to use the Corporate root.master that was provided as an example and this would still happen.

If anyone can give me some direction on where to go for this, it would be greatly appreciated.

User avatar
Member
Member
beau.cowan-rrpartners - 2/11/2013 12:34:52 PM
   
RE:Error on Root page and properties tab
Edit:

I found a solution for Problem #1.
In the General.aspx file, it is using
<%@ Page Language="C#" AutoEventWireup="true" Inherits="CMSModules_Content_CMSDesk_Properties_General"
Theme="Default" MaintainScrollPositionOnPostback="true" Codebehind="General.aspx.cs"
MasterPageFile="~/CMSMasterPages/UI/SimplePage.master" %>

I change Codebehind to CodeFile and now it works just fine on localhost
<%@ Page Language="C#" AutoEventWireup="true" Inherits="CMSModules_Content_CMSDesk_Properties_General"
Theme="Default" MaintainScrollPositionOnPostback="true" CodeFile="General.aspx.cs"
MasterPageFile="~/CMSMasterPages/UI/SimplePage.master" %>

I'm still having issues with the second problem though. I will continue to research unless someone thinks they might have a solution.

User avatar
Member
Member
beau.cowan-rrpartners - 2/11/2013 3:40:04 PM
   
RE:Error on Root page and properties tab
Found the fix for Problem #2, courtesy of the development guide, http://devnet.kentico.com/docs/7_0/devguide/index.html?using_the_master_pages.htm

Since it was an upgrade from 6 to 7, the order in my Root.Master was as follows:
<asp:PlaceHolder runat="server" ID="plcManagers">
<cms:CMSPortalManager ID="manPortal" runat="server" EnableViewState="false" />
<ajaxToolkit:ToolkitScriptManager ID="manScript" runat="server" EnableViewState="false" ScriptMode="Release" />
</asp:PlaceHolder>

I simply had to flip the lines like so:
<asp:PlaceHolder runat="server" ID="plcManagers">
<ajaxToolkit:ToolkitScriptManager ID="manScript" runat="server" EnableViewState="false" ScriptMode="Release" />
<cms:CMSPortalManager ID="manPortal" runat="server" EnableViewState="false" />
</asp:PlaceHolder>

And now it all works as it should.

User avatar
Kentico Customer Success
Kentico Customer Success
kentico_martind2 - 2/12/2013 2:46:39 AM
   
RE:Error on Root page and properties tab
Hi Beau,

Thanks for letting us know.

#1 I've never heard about CodeBehind property but CodeFile is the standard one as I know. You can see it also everywhere in the Documentation.

#2 Yes, because as it is mentioned in the Developers Guide...
CMSPortalManager - ensures the transferring of content between the database and editable regions. It also provides the management functionality needed for portal engine zones. Always place this control after the ToolkitScriptManager control.

Anyway, I'm really glad that you was able to find out the solutions in our Developers Guide.

Best regards,
Martin Danko