I have build an EPiServer 7 version of Erik Nordins tool that can be found at http://talk.alfnilsson.se/2013/03/08/creating-page-type-classes-from-page-types-in-episerver-cms-7/
Make sure that the GUID of your created page type class and the page type in the database is the same.
All your created Page Types have to inherit from PageData or a sub class that inherits PageData.
The other option is to manually edit your Page Type Builder classes and replace the Attributes with EPiServer 7 attributes instead
Thanks for your answer Alf. Actually I am using your tool. Added the wrong URL in the post.
I will give it a try and post the result here.
Marked as answered.
Used the tool to convert my classes and using the same GUID did the trick. Thanks for your answer Alf!
We are currently using PageTypeBuilder and want to replace it with EpiServer 7 built in page type support.
To avoid recreating pages on the site I am looking for a way to replace the class created in PTB with the new way, and to avoid loosing information created by the editors.
This is the tool I am using to convert classes: https://github.com/eriknordin/PTB-Helpers
Next step is to change the inheritance on the template to EpiServer.TemplatePage<T> where T is the class built with EpiServer 7 page type support.
By visiting the page this error occur:
ContentData Cast. The requested type Class is not compatible with Castle.Proxies.ClassTypeProxy
Since I change the type on the template this error seems fair.
I am not really sure about the next step. If we look in the database (tables tblcontent and tblcontenttype) the page created in edit mode is connected to the class genereted by PTB and not my new one of course.
Do I have do modify the database in some way? or have I missed something in my steps above?
The goal here is to make sure nothing is loost when deploying our website.
All help is appreciated!