Hi all,
We are still using CRM 2015 for now and have kicked off a D365 migration project.
However for the time being, the business have come across an issue with trying to import data back into CRM.
Scenario:
User export cases data by clicking on EXPORT TO EXCEL

User then opens file in Excel 365 app (not cloud) and adds data in then clicks on the IMPORT DATA button

However, a vauage error pops up

After trace log, I can see this error:
MSCRM Error Report:
--------------------------------------------------------------------------------------------------------
Error: Object reference not set to an instance of an object.
Error Message: Object reference not set to an instance of an object.
Source File: Not available
Line Number: Not available
Request URL:
Stack Trace Info: [NullReferenceException: Object reference not set to an instance of an object.]
at Microsoft.Xrm.Office.ExcelReader.GetColumnFormat(Int32 colIndex)
at Microsoft.Xrm.Office.ExcelReader.<ParseHeaderRow>b__3(String stringValue, Int32 index)
at System.Linq.Enumerable.<SelectIterator>d__5`2.MoveNext()
at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at Microsoft.Xrm.Office.ExcelReader.get_Columns()
at Microsoft.Xrm.Office.ExcelReader.ParseDataRows(IEnumerable`1 dataRows)
at Microsoft.Xrm.Office.ExcelReader.get_Rows()
at Microsoft.Crm.Spreadsheet.SpreadsheetAdapter.Validate()
at Microsoft.Crm.Application.Pages.Import.ImportFileUploadPage.PopulateExcelMetadata(Byte[] fileContent)
at Microsoft.Crm.Application.Pages.Import.ImportFileUploadPage.ProcessFileForImport(Byte[] inputBytes, Int32 inputLength, String contentType, String shortName)
at Microsoft.Crm.Application.Pages.Import.ImportFileUploadPage.ProcessFile()
at Microsoft.Crm.Application.Pages.Import.ImportFileUploadPage.ConfigureForm()
Thing I have noticed:
- If I open the Excel file and do nothing but click Save, the file size increases by about 10KB, it will then error when I try to upload.
- If I open the Excel file and amend some data then click Save, it will then error when I try to upload.
- If I open the file but then do nothing and close it and try to upalod, there's no error and it successfully gets uploaded.
My conclusion is that Excel is to blame here, so I've tried to downgrade my 365 office installation to the August 2020 version, and lo' and behold, amending the exported Excel file and uploading works!
However, we can't really downgrade everyones Office version, so im wondering if anyone has any ideas?
------------------------------
Giovanni Vetere
Westcoast Ltd
UK
------------------------------