laptop and a wrench

Bug

Using ExecuteCommandArgs to open a dock pane empties the DockpaneManager object, not allowing it to to open any dock pane in ArcGIS Pro SDK for .NET.

ArcGIS Pro SDK for .NET
Bug ID Number BUG-000174299
SubmittedFebruary 12, 2025
Last ModifiedMarch 11, 2025
Applies toArcGIS Pro SDK for .NET
Version found3.3
Operating SystemWindows OS
Operating System Version11.0 64 bit
StatusWill Not Be Addressed

Additional Information

Do not use the QueuedTask to open the dockpane. It has to be opened on the UI thread.

Workaround

Do not use the QueuedTask to open the dock pane. It has to be opened on the UI thread. Try this instead: protected override Func ExecuteCommandArgs(string id) { try { ArcGIS.Desktop.Framework.Dialogs.MessageBox.Show($"message: {id}"); // Run the command specified by the id passed into ExecuteCommandArgs IPlugInWrapper wrapper = FrameworkApplication.GetPlugInWrapper(id); var command = wrapper as ICommand; if (command != null && command.CanExecute(null)) command.Execute(null); } catch (System.Exception e) { ArcGIS.Desktop.Framework.Dialogs.MessageBox.Show($"ERROR: {e}", "Error running command"); } return (object[] args) => DoNothing(); } private Task DoNothing() { return Task.CompletedTask; }

Steps to Reproduce

Bug ID: BUG-000174299

Software:

  • ArcGIS Pro SDK for .NET

Get notified when the status of a bug changes

Download the Esri Support App

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options