ASPX templates
Version 7.x > ASPX templates > Debuggin LoadOrphanedZones On Master Page View modes: 
User avatar
Member
Member
bryanallott - 3/29/2013 4:38:49 AM
   
Debuggin LoadOrphanedZones On Master Page
After importing a site, I'm getting a null reference exception on the master template in the function "LoadOrphanedZones".
Page error:
There was an error processing the page. The error can be caused by the configuration of some component on the master page. Check the master page configuration or see event log for more details. Original message: Object reference not set to an instance of an object.

Event log displays this:
Message: Object reference not set to an instance of an object.
Stack Trace:
at CMS.PortalControls.CMSPagePlaceholder.LoadOrphanedZones(Boolean reloadData)
at CMS.PortalControls.CMSPortalManager.LoadContent(Boolean reloadData)
at CMS.PortalControls.CMSPortalManager.CMSPortalManager_Init(Object sender, EventArgs e)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Is there something obvious I've missed or would I need to try setup remote debugging to troubleshoot?

User avatar
Kentico Customer Success
Kentico Customer Success
kentico_martind2 - 3/29/2013 8:35:29 AM
   
RE:Debuggin LoadOrphanedZones On Master Page
Hello Bryan,

are you using any Custom Web Parts in that master page? One thing I would recommend you too... please check the API Documentation of method LoadOrphanedZones.

Best regards,
Martin Danko

User avatar
Member
Member
bryanallott - 4/2/2013 4:11:50 AM
   
RE:Debuggin LoadOrphanedZones On Master Page
Thanks, Martin. Yes, there are a number of custom web parts. Right, I'll look into it then with more detail.

User avatar
Member
Member
bryanallott - 5/6/2013 3:09:31 PM
   
RE:Debuggin LoadOrphanedZones On Master Page
for posterity... after doing a site import, and then getting a null reference exception on the master template... => check that the root document node has indeed been assigned a master page. somehow, after an import, that setting was lost in this case. assigning a master page template to the root document sorted it out.