You must get rid of your Form-properties and convert them to EPiServer XForm before you can migrate them to EPiServer 5.
You can easily identify all form-properties on you site with some SQL:
SELECT pt.pkID AS PageTypeId, pt.Name as PageType, pd.Name AS PropertyName, pt.Filename
FROM tblPageDefinition AS pd
INNER JOIN tblPageType AS pt ON pd.fkPageTypeID = pt.pkID
WHERE (pd.fkPageDefinitionTypeID = 9)
ORDER BY pt.SortOrder, pd.FieldOrder
In admin mode there is a XForm Convert tool that can be used to convert existing Forms into XForms.
One of the differences between Forms and XForms is that the data for a Form is stored on a page but XForms are stored as a separate object in the ObjectStore.
The XForm property on you page only stores a GUID in a string that is a reference to the real XForm instance.
Do not change the type on an existing property from Form to XForm. That will only give you exceptions. Instead, create new properties and delete the old ones.
If you want better control over the conversion process use Lutz Reorder’s reflector to reverse engineer the class EPiServer.Admin.ConvertFormToXform in EPiServer.CodeBehind.dll.
Tags: 4.62, EPiServer, Form, MigrationTool, XForm
-
One thing that should be mentioned. When you convert forms from the old format to the XForm format, the posted data will not be converted. One should export the old data to Excel if one want to keep the old posted data.
Also I had some problems with this default xform converter when upgrading from 4.41 to 4.61. I asked about it someone from episerver and they had sent me other convert tool that worked much better. -
Thanks for this info.
I want to add a sql script that is useful to use if you want to get hold of a pageid list of all pages in the EPiServer solution that uses the old form property:
SELECT [fkPageID] as PageID
FROM [tblProperty]
INNER JOIN [tblPageDefinition] AS pd ON [tblProperty].fkPageDefinitionID = pd.pkID
WHERE pd.Name = ‘MainForm’This is useful if the old form property (in my case ‘Mainform’) is used on multiple pagetypes.

![Fredrik Haglund [Photo by: Kristina Sahlén]](http://blog.fredrikhaglund.se/wp-content/uploads/2010/03/fredrik200.jpg)

3 comments
Comments feed for this article
Trackback link: http://blog.fredrikhaglund.se/blog/2008/03/19/convert-episerver-form-to-xform/trackback/