Hi all
I've created a site template ans tried to create a new SC based in the template. The templated site gets created (Top Level) but an error is reported. I ignored the error as everthing looked ok.
I then tried to swith on Publishing when a error was reported, i've discovered that some of the pages (site settings > Masterpages) Associated Content Type has a #VALUE!. In my original site these seem fine with correct CT's.
When I created the original site I switched on SharePoint Publishing Infrastructure and Publishing for the site. Then decided against publishing feature and switched it off(cant template with publishing on as it is). I created the template without
Publishing Infrastructure and Publishing Features.
Somehow I think some of the publishing attributes are being passed into the template though I've switched them off. Here is the error message when I create a templated site.
<nativehr>0x8107058a</nativehr><nativestack></nativestack>Invalid URI: The URI scheme is not valid.
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.Runtime.InteropServices.COMException: <nativehr>0x8107058a</nativehr><nativestack></nativestack>Invalid URI: The URI scheme is not valid.
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.
[COMException (0x8107058a): <nativehr>0x8107058a</nativehr><nativestack></nativestack>Invalid URI: The URI scheme is not valid.]
Microsoft.SharePoint.Library.SPRequestInternalClass.ApplyWebTemplate(String bstrUrl, String bstrWebTemplateContent, Int32 fWebTemplateContentFromSubweb, Int32 fDeleteGlobalListsWithWebTemplateContent, String& bstrWebTemplate, Int32& plWebTemplateId) +0
Microsoft.SharePoint.Library.SPRequest.ApplyWebTemplate(String bstrUrl, String bstrWebTemplateContent, Int32 fWebTemplateContentFromSubweb, Int32 fDeleteGlobalListsWithWebTemplateContent, String& bstrWebTemplate, Int32& plWebTemplateId) +172
[SPException: Invalid URI: The URI scheme is not valid.]
Microsoft.SharePoint.SPGlobal.HandleComException(COMException comEx) +27992434
Microsoft.SharePoint.Library.SPRequest.ApplyWebTemplate(String bstrUrl, String bstrWebTemplateContent, Int32 fWebTemplateContentFromSubweb, Int32 fDeleteGlobalListsWithWebTemplateContent, String& bstrWebTemplate, Int32& plWebTemplateId) +28206803
Microsoft.SharePoint.SPWeb.ApplyWebTemplate(String strWebTemplate) +1218
Microsoft.SharePoint.ApplicationPages.TemplatePickerUtil.ApplyWebTemplateAndRedirect(SPWeb Web, String strWebTemplate, Nullable`1 bSharedNav, Boolean bOnTopNav, Boolean bOnQuickLaunch, Page page, Boolean bDeleteOnError) +1870
Microsoft.SharePoint.ApplicationPages.TemplatePickPage.BtnSubmit_Click(Object sender, EventArgs e) +129
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +115
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +140
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +29
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2981
And here is original Master Page screen shot:
![]()
and the templated version (faulty)
![]()
UPDATE:
Created a new sc with team template, activated Sharepoint Publishing Infrastructure. Exported as site template. Crreated new site from template (without error) however when I look at Master Pages and associated columns it shows #VALUE! in most.
When clicked on link #VALUE! get error:
Value does not fall within the expected range
When try to activate 'SharePoint Server Publishing' error reported:
Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index