Sebastian Leupold wrote
... same version of the module, you should easily be able to export/import the module with all its data.
Hi Sebastian
Many thanks, that's exactly what I need to do. Both sites are DNN Prof 5.1.4 and both use version 5.0.3 of the FnL module.
With DNN in edit mode, I can use the FnL "Export" option in the FnL menu. With this I can export the data from the FnL modules in the Portal to an xml file.
example filename: "content.DNNUserDefinedTable.TheResponsiblePharmacistRecordforBarbourne.xml"
Note: As I cannot attach files to this msg, the XML follows
But ----- I've removed several <data> elements from the middle.
And ----- I've removed several <Fields> elements from the middle.
===============
FnL XML Export File
===============
<?xml version="1.0" encoding="utf-8" ?>
<content type="DNNUserDefinedTable" version="05.00.03">
<UserDefinedTable xmlns="DotNetNuke/UserDefinedTable">
<Data>
<UserDefinedRowId>1679</UserDefinedRowId>
<Branch>Test Branch</Branch>
<Date_x002F_Time_x0020_record_x0020_created>2009-09-23T15:13:18+01:00</Date_x002F_Time_x0020_record_x0020_created>
<Name />
<RPSGB_x0020_No />
<Time_x0020_RP_x0020_responsibility_x0020_starts_x002F_ends>0001-01-01T09:00:00+00:00</Time_x0020_RP_x0020_responsibility_x0020_starts_x002F_ends>
<Record_x0020_Type>Start</Record_x0020_Type>
<Notes_x0020__x002F__x0020_Reason_x0020_for_x0020_absence />
<Created_x0020_by>administrator</Created_x0020_by>
<Changed_x0020_by>administrator</Changed_x0020_by>
<Changed_x0020_at>2009-09-23T15:13:18+01:00</Changed_x0020_at>
</Data>
----- >>> SNIP <Data> Elements <<< -----
<Fields>
<UserDefinedFieldId>632</UserDefinedFieldId>
<ModuleID>1090</ModuleID>
<FieldTitle>Branch</FieldTitle>
<Required>true</Required>
<FieldOrder>0</FieldOrder>
<FieldType>String</FieldType>
<default>Barbourne</default>
<Visible>true</Visible>
<ShowOnEdit>true</ShowOnEdit>
<Searchable>false</Searchable>
<PrivateField>false</PrivateField>
<NormalizeFlag>false</NormalizeFlag>
<ValueColumn>Branch</ValueColumn>
<SortColumn>Branch</SortColumn>
</Fields>
<Fields>
<UserDefinedFieldId>633</UserDefinedFieldId>
<ModuleID>1090</ModuleID>
<FieldTitle>Date/Time record created</FieldTitle>
<Required>true</Required>
<FieldOrder>1</FieldOrder>
<FieldType>CreatedAt</FieldType>
<Visible>true</Visible>
<ShowOnEdit>false</ShowOnEdit>
<Searchable>true</Searchable>
<PrivateField>false</PrivateField>
<NormalizeFlag>false</NormalizeFlag>
<ValueColumn>Date_x002F_Time_x0020_record_x0020_created</ValueColumn>
<SortColumn>Date_x002F_Time_x0020_record_x0020_created</SortColumn>
</Fields>
----- >>> SNIP <Fields> Elements <<< -----
<Settings Setting="UDT_CnCLink" Value="False" />
<Settings Setting="UDT_EditOnlyOwnItems" Value="True" />
<Settings Setting="UDT_EditPrivateColumnsForAdmins" Value="True" />
<Settings Setting="UDT_ForceCaptchaForAnonymous" Value="False" />
<Settings Setting="UDT_ForceDownload" Value="False" />
<Settings Setting="UDT_ForceFiltering" Value="False" />
<Settings Setting="UDT_ImageHeight" Value="" />
<Settings Setting="UDT_ImageWidth" Value="" />
<Settings Setting="UDT_ShowAllColumnsForAdmins" Value="True" />
<Settings Setting="UDT_TopCount" Value="" />
<Settings Setting="UDT_URLNewWindow" Value="False" />
<Settings Setting="UDT_UserLinkNewWindow" Value="False" />
<Settings Setting="UDT_UserLinkUserName" Value="DisplayName" />
<Settings Setting="UDT_UserRecordQuota" Value="" />
</UserDefinedTable>
</content>
I then copied the export file across to the new site and imported the data, using the FnL "Import" menu, the import appeared to work ok.
However - When I view the new module no data (or grid) is shown and the following error message is shown on screen:
Warning icon (orange triangle)
Data Binding Failed. This issue may be caused by an unsupported cast of a data type.
Error Description: Object reference not set to an instance of an object
Opening the "form and List Configuration" screen shows that the settings do match those of the original FnL module.
including the colums in the user defined table in the "Data Table Setup" area.
The original FnL module did have a few records but those cannot be seen in the new module where the data was imported.
Looking in the "Admin" | "Event Viewer" Three General Exceptions are raised each time the new FnL module is viewed.
======================
EXCEPTION #01
======================
AssemblyVersion: 5.1.4
PortalID: 0
PortalName: MyWorkspace
UserID: 1
UserName: host
ActiveTabID: 534
ActiveTabName: RP Master Record
RawURL: /RPRecords/RPMasterRecord/tabid/534/language/en-GB/Default.aspx
AbsoluteURL: /Default.aspx
AbsoluteURLReferrer: http://myworkspace/Admin/Tabs/tabid/40/language/en-GB/Default.aspx
UserAgent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.0.50727; .NET CLR 1.1.4322; .NET CLR 1.0.3705; InfoPath.1; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; OfficeLiveConnector.1.3; OfficeLivePatch.0.0; MS-RTC LM 8)
DefaultDataProvider: DotNetNuke.Data.SqlDataProvider, DotNetNuke.SqlDataProvider
ExceptionGUID: 96c32f6e-7dc9-4a19-a729-f3430c437a44
InnerException: Object reference not set to an instance of an object.
FileName:
FileLineNumber: 0
FileColumnNumber: 0
Method: DotNetNuke.Services.Tokens.BaseCustomTokenReplace.replacedTokenValue
StackTrace:
Message: System.NullReferenceException: Object reference not set to an instance of an object. at DotNetNuke.Services.Tokens.BaseCustomTokenReplace.replacedTokenValue(String strObjectName, String strPropertyName, String strformat) at DotNetNuke.Services.Tokens.BaseTokenReplace.ReplaceTokens(String strSourceText) at DotNetNuke.Modules.UserDefinedTable.DataTypeLookUp.TokenReplace.GetValue(String tokenText, DataRow row, String sourceColumn, String sourceType) at DotNetNuke.Modules.UserDefinedTable.DataTypeLookUp.RenderValuesToHtmlInsideDataSet(DataSet ds, Int32 ModuleId, Boolean noScript) at DotNetNuke.Modules.UserDefinedTable.UserDefinedTableController.RenderValuesToHtmlInsideDataSet(DataSet ds) at DotNetNuke.Modules.UserDefinedTable.UserDefinedTableController.GetDataSet(Boolean WithPreRenderedValues) at DotNetNuke.Modules.UserDefinedTable.List.get_DataSet() at DotNetNuke.Modules.UserDefinedTable.List.BindData() at DotNetNuke.Modules.UserDefinedTable.List.Page_PreRender(Object sender, EventArgs e)
Source:
Server Name: LON-LAS
======================
EXCEPTION #02
======================
AssemblyVersion: 5.1.4
PortalID: 0
PortalName: MyWorkspace
UserID: 1
UserName: host
ActiveTabID: 534
ActiveTabName: RP Master Record
RawURL: /RPRecords/RPMasterRecord/tabid/534/language/en-GB/Default.aspx
AbsoluteURL: /Default.aspx
AbsoluteURLReferrer: http://myworkspace/Admin/Tabs/tabid/40/language/en-GB/Default.aspx
UserAgent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.0.50727; .NET CLR 1.1.4322; .NET CLR 1.0.3705; InfoPath.1; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; OfficeLiveConnector.1.3; OfficeLivePatch.0.0; MS-RTC LM 8)
DefaultDataProvider: DotNetNuke.Data.SqlDataProvider, DotNetNuke.SqlDataProvider
ExceptionGUID: 7dd4e61c-3156-47f6-866f-48c332fcf01f
InnerException: Object reference not set to an instance of an object.
FileName:
FileLineNumber: 0
FileColumnNumber: 0
Method: DotNetNuke.Services.Tokens.BaseCustomTokenReplace.replacedTokenValue
StackTrace:
Message: System.NullReferenceException: Object reference not set to an instance of an object. at DotNetNuke.Services.Tokens.BaseCustomTokenReplace.replacedTokenValue(String strObjectName, String strPropertyName, String strformat) at DotNetNuke.Services.Tokens.BaseTokenReplace.ReplaceTokens(String strSourceText) at DotNetNuke.Modules.UserDefinedTable.DataTypeLookUp.TokenReplace.GetValue(String tokenText, DataRow row, String sourceColumn, String sourceType) at DotNetNuke.Modules.UserDefinedTable.DataTypeLookUp.RenderValuesToHtmlInsideDataSet(DataSet ds, Int32 ModuleId, Boolean noScript) at DotNetNuke.Modules.UserDefinedTable.UserDefinedTableController.RenderValuesToHtmlInsideDataSet(DataSet ds) at DotNetNuke.Modules.UserDefinedTable.UserDefinedTableController.GetDataSet(Boolean WithPreRenderedValues) at DotNetNuke.Modules.UserDefinedTable.List.get_DataSet() at DotNetNuke.Modules.UserDefinedTable.List.get_ModuleActions()
Source:
Server Name: LON-LAS
======================
EXCEPTION #03
======================
AssemblyVersion: 5.1.4
PortalID: 0
PortalName: MyWorkspace
UserID: 1
UserName: host
ActiveTabID: 534
ActiveTabName: RP Master Record
RawURL: /RPRecords/RPMasterRecord/tabid/534/language/en-GB/Default.aspx
AbsoluteURL: /Default.aspx
AbsoluteURLReferrer: http://myworkspace/Admin/Tabs/tabid/40/language/en-GB/Default.aspx
UserAgent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.0.50727; .NET CLR 1.1.4322; .NET CLR 1.0.3705; InfoPath.1; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; OfficeLiveConnector.1.3; OfficeLivePatch.0.0; MS-RTC LM 8)
DefaultDataProvider: DotNetNuke.Data.SqlDataProvider, DotNetNuke.SqlDataProvider
ExceptionGUID: a4462f4b-ae55-474d-954e-e5e597f362d2
InnerException: Object reference not set to an instance of an object.
FileName:
FileLineNumber: 0
FileColumnNumber: 0
Method: DotNetNuke.Services.Tokens.BaseCustomTokenReplace.replacedTokenValue
StackTrace:
Message: System.NullReferenceException: Object reference not set to an instance of an object. at DotNetNuke.Services.Tokens.BaseCustomTokenReplace.replacedTokenValue(String strObjectName, String strPropertyName, String strformat) at DotNetNuke.Services.Tokens.BaseTokenReplace.ReplaceTokens(String strSourceText) at DotNetNuke.Modules.UserDefinedTable.DataTypeLookUp.TokenReplace.GetValue(String tokenText, DataRow row, String sourceColumn, String sourceType) at DotNetNuke.Modules.UserDefinedTable.DataTypeLookUp.RenderValuesToHtmlInsideDataSet(DataSet ds, Int32 ModuleId, Boolean noScript) at DotNetNuke.Modules.UserDefinedTable.UserDefinedTableController.RenderValuesToHtmlInsideDataSet(DataSet ds) at DotNetNuke.Modules.UserDefinedTable.UserDefinedTableController.GetDataSet(Boolean WithPreRenderedValues) at DotNetNuke.Modules.UserDefinedTable.List.get_DataSet() at DotNetNuke.Modules.UserDefinedTable.List.SearchManager.LoadColumns() at DotNetNuke.Modules.UserDefinedTable.List.SearchManager.SearchControl(SearchControlTypes ControlType) at DotNetNuke.Modules.UserDefinedTable.List.SearchManager.LoadControls() at DotNetNuke.Modules.UserDefinedTable.List.Page_Init(Object sender, EventArgs e)
Source:
Server Name: LON-LAS
Many thanks for your help - Guy