Question

We have the following scenario and are hoping someone can help:

  • Original 2007 Publishing Site content database upgraded to 2010
  • Page templates in use have never been Ghosted because they were manually added and are not part of the site definition, so their SPFile.CustomizedPageStatus property is set to 'None'
  • Our updated templates are in a VS2010 deployment package, which is deployed via a feature (the deployment fails due to previous point)
  • We've so far been unable to change CustomizedPageStatus via PowerShell or SPFile.RevertContentStream() because CustomizedPageStatus is set to 'None'. This method throws an exception by design if the property is 'None'

Ideally, we'd like to update the property to 'Uncustomized' (for example), so that the deployment will update all the files.

Entries in the Elements.xml file are in the following format:

<File Url="CustomMasterPage.master" Type="GhostableInLibrary" />   

Grateful for any assistance.

Was it helpful?

Solution

We have now found a temporary solution using the following tool:

http://spghostfilesmanager.codeplex.com/

We renamed our page templates in the feature, deployed them as normal, then used the Ghost Files Manager to "wire up" the templates to the new ones.

It's a bit of a hack to be honest, but it has allowed us to continue.

If anyone has any better suggestions on how to achieve this, please post!

OTHER TIPS

You can also use SharePoint Designer, if installed.

Go to the relevant page in the Master page gallery, and if it has a blue "!" icon next to it, click "Reset to Site Definition". This will reload the relevant page from the hive.

But all customizations done to the current version of the page will be lost!

i believe the soluition is to revert to site definition (SharePintDesigner) and then deploy the solution again(VisualStudio)

It worked for me! Just insure in visual studio that the item "Deployment Conflict Resolution" is set to "None"

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top