Warning_Data.ImportExcel operation failed

Hi guys, is there any stable solution to this problem rather than repair every time???
https://www.autodesk.com/support/technical/article/caas/sfdcarticles/sfdcarticles/Warning-Data-ImportExcel-operation-failed-Could-not-load-file-or-assembly-Microsoft-Office-Interop-Excel-when-running-the-Dynamo-script-in-Revit.html
We have been dealing with this for over a year!
We repair it, and one week later we need to repair it again for almost every user in the company?

by the way it happens consistenly in Dynamo for Revit 2021 and 2022 on Windows 2010 and 2011 and on all MS Office versions

Try and utilise the OpenXml version of this node going forward as it seems to work better.

We tried but that node is very limited in comparison to the other one

The other issue isn’t something that Dynamo or Autodesk can fix. The excel nodes rely on the Excel Interop API which MS breaks on updates to their products. The break usually traces back to the old Registry entry persisting, while the new one is the one which needs to be leveraged.

A no way exhaustive or verified list of products I’ve seen/heard have updates that cause the issue: Excel (absolutely related), Office (ok, related again), PowerBI (I guess relatedish due to the interop tools), Windows (huh?), Teams (nope), Edge (you’re kidding right?), and likely others…

This doesn’t just impact Dynamo, but any tool which relies on that API can (and will) break. The web is littered with products indicating the fix is to ‘repair excel’.

For Dynamo users, the options are:

  • Switch to the OpenXML nodes or another format
  • Stop updating all MS products (this is a bad Idea but I’m giving any option that comes to mind)
  • Lobby MS to ensure the API stays stable on all updates (one can dream)
  • Do an Excel repair every time you run into the problem (sadly hard to manage at scale as this is per machine)

Personally I recommend moving to JSON or CSV for extraction of data, when needed you can linking those into Excel to get formaulas and such working without issue. If you need to read you can use the OpenXML nodes or do an export on the data you want before reading into Dynamo.

2 Likes