Select to view content in your preferred language

Custom Print Addin

257
0
10-11-2022 12:09 AM
imrankhadri
New Contributor II

We have a requirement to create a Addin that prints a layout. Prior to ArcGIS pro, it was possible to do the same using PrintAndExportClass in ArcMap. Do we have anything  equivalent in PRO?

I am aware of invoking the esri_sharing_PrintMap command. However, my main requirement is to listen to print events as I need to do some post print operations. Is there a way to capture print events like Cancel, AfterPrint etc?.

IPlugInWrapper wrapper = FrameworkApplication.GetPlugInWrapper("esri_sharing_PrintMap");
var command = wrapper as ICommand; 
if ((command != null) && command.CanExecute(null))
command.Execute(null);‍‍‍‍

0 Kudos
0 Replies