How to add a ProWindow without a ribbon button?

1141
1
Jump to solution
01-10-2020 07:39 AM
CraigStephens1
New Contributor II

ArcGIS Pro SDK for Microsoft .NET 2.4

Visual Studio 2019

When adding an ArcGIS Pro ProWindow to our add-in, a ribbon button is also added to activate that window.  That's all good.

However, when I need a window that will be activated from within an existing window, using the template to create a new ProWindow and then deleting the ribbon button that comes with it is a bother.

Assuming that using a ProWindow for all dialogs is the correct pattern for styling reasons (vs. a standard WPF window), is there a cleaner way to add a ProWindow?  Or, should I be doing something different?

0 Kudos
1 Solution

Accepted Solutions
Wolf
by Esri Regular Contributor
Esri Regular Contributor

When we designed our item templates we tried to deliver an implementation that can be compiled, debugged, and seen in action without any additional coding.  As a result we automatically generate buttons where needed, like for example for ProWindow or Dockpane.  The stubbed out button code provides the code snippet needed to activate the ProWindow or Dockpane.  If you need a ProWindow item template without the buttons to improve your productivity,  you can create your own Visual Studio item template as shown here: https://docs.microsoft.com/en-us/visualstudio/ide/how-to-create-item-templates?view=vs-2019 

In regards to whether using ProWindows for all dialogs is the correct pattern for styling, i would suggest to find a  workflow in ArcGIS Pro that matches closest your desired custom workflow and use the same styling pattern than Pro is using.  For example: ArcGIS Pro Property Dialogs for the most part are ProWindows, ArcGIS Pro workflow configuration settings (i.e. GeoProcessing) are usually in Dockpanes, ArcGIS Pro Metadata is usually a Pane.

I hope this helps,

View solution in original post

1 Reply
Wolf
by Esri Regular Contributor
Esri Regular Contributor

When we designed our item templates we tried to deliver an implementation that can be compiled, debugged, and seen in action without any additional coding.  As a result we automatically generate buttons where needed, like for example for ProWindow or Dockpane.  The stubbed out button code provides the code snippet needed to activate the ProWindow or Dockpane.  If you need a ProWindow item template without the buttons to improve your productivity,  you can create your own Visual Studio item template as shown here: https://docs.microsoft.com/en-us/visualstudio/ide/how-to-create-item-templates?view=vs-2019 

In regards to whether using ProWindows for all dialogs is the correct pattern for styling, i would suggest to find a  workflow in ArcGIS Pro that matches closest your desired custom workflow and use the same styling pattern than Pro is using.  For example: ArcGIS Pro Property Dialogs for the most part are ProWindows, ArcGIS Pro workflow configuration settings (i.e. GeoProcessing) are usually in Dockpanes, ArcGIS Pro Metadata is usually a Pane.

I hope this helps,