Select to view content in your preferred language

Arcpy: Provide explicit GP parameter data type for ArcGIS Pro projects (including support for "CURRENT" keyword)

03-15-2023 01:31 PM
Status: Open
Labels (1)
New Contributor III

It would be very helpful, to have an explicit data type "ArcGIS Pro projects" (e.g. "DEProProject") to use for GP parameters (including the special "CURRENT" keyword):

param = arcpy.Parameter("pro_project", "ArcGIS Pro Project", "Input", ==>"DEProProject"<==, "Required")

Currently the only workaround is to use the type "DEFile" and define the parameter filter list as shown below and using "CURRENT" as value:

param = arcpy.Parameter("pro_project", "ArcGIS Pro Project", "Input", "DEFile", "Required")

param.filter.list = ["", "aprx"]
param.value = "CURRENT"


Status changed to: Needs Clarification

Hello @ChristophKoschmieder and thank you for your suggestion of creating an explicit data type for ArcGIS Pro projects!

We appreciate your feedback and are interested in learning more about your specific use case(s) for this data type. Could you please provide more details on how this would benefit your workflows and what specific tasks you would use it for?

Understanding the context and needs of our users helps us prioritize and design new features that can provide the most value.

Thank you again for your input, and we look forward to hearing back from you.


Hello Hannes,

I am working on a number of projects where we provide additional functionality to ArcGIS by implementing geoprocessing tools with Python (which is always our first choice).

One use-case for the explicit parameter data type is the following:

  • For an AGP project (or "CURRENT", if executed in AGP for the project currently loaded)
  • determine the layouts, which exist in this project in order to
  • get the names and content of the text elements on this layout (as a value table)

The user can then modify the content of those text elements and by executing the GP tool the changes are written to the text elements in the layout.



Status changed to: Open

Thanks @ChristophKoschmieder for providing more information about your use case. We can see how this could be useful for streamlining workflows.

While it is possible to achieve a similar effect with the current DEFile parameter type and a filter list that includes "aprx", we understand that having a dedicated data type could simplify the process for users.

We encourage you to give your idea a "kudos" by clicking the thumbs up icon on the post (your kudos is not automatically applied to your own post). This helps us understand how much demand there is for a particular feature and can ultimately influence prioritization.

Thank you again for your suggestion, and please don't hesitate if you want to share any further ideas or feedback.