Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

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.

share|improve this question
add comment

3 Answers

up vote 0 down vote accepted

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!

share|improve this answer
add comment

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!

share|improve this answer
    
Unfortunately, this doesn't work if the template has never been Ghosted (i.e. status is None). It was never part of the site definition because it was uploaded as a custom template. Thanks for the suggestion. –  ioan Mar 7 '13 at 16:32
add comment

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"

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.