Excel: No prompt to save changes on close after running Dynamo

When I use Dynamo to populate a spreadsheet, it seems to prevent Excel from asking if I want to save on close even if I manually made changes after the graph was run. This happens for every spreadsheet I have open, not just the one(s) modified by Dynamo. It only seems to start asking again once the Excel process ends (which doesn’t necessarily happen when all the files are closed) and Excel is opened again. I’m concerned about loss of data when people rely on the notification to remind them to save.

Has anyone else come across this, and are there any ways to get around this? We’re currently using Dynamo 1.3.4. Would upgrading to a more current version address this?

Thanks for your help!

Kenny

I believe this is a limitation of the excel api. Set the graph to not show excel to help reduce the likelihood of this occurring.

Sorry for the late reply. How do you set the graph to not show Excel? I don’t see any option for that.

I’ve also tried writing a Python script to change this setting after it’s done writing to Excel, but it doesn’t seem to fix the problem. I’ve attached the file I’ve been testing this on, but here’s the Python script I tried as well:

import clr
clr.AddReferenceByName(‘Microsoft.Office.Interop.Excel’)
import Microsoft.Office.Interop.Excel as Excel

ex = Excel.ApplicationClass()
ex.Visible = True
ex.DisplayAlerts = True

Thanks!

Excel Display Alerts.dyn (4.5 KB)

Sorry I had the red/write nodes confused in my head. Best to submit a feature request to get the export to act like the import.

Import node:
https://dictionary.dynamobim.com/2/#/ImportExport/Data/Action/ImportExcel

Request:

Will do, thanks Jacob! If I’m able to find a workaround in the meantime I’ll be sure to post a solution here.

1 Like