ArcGIS Pro - How do I prevent a project from saving in C# code?

238
0
02-19-2020 11:24 AM
RichardDaniels
Regular Contributor

When a project is closed and a new project is loaded, the API will attempt to save the previous project IF the project is dirty -not saved since last edit or add data operation.

 Solution:

Project.Current.SetDirty(false);

this will prevent the ArcGIS Pro project save window from appearing (with an undocumented exception if you select Cancel :-).

Tags (2)
0 Replies