I am working on creating an ArcGIS tool from a Python script I am writing. I am wondering if it is possible to have a checkbox parameter. Basically what I want to do is have a parameter where the user selects a feature class, then from the feature class the user will choose the field for the upper most layer in their model, then I want the user to be able to choose what layers they want the script to run on with a checkbox structure derived from the upper most layer field. Is this possible with python, and ArcGIS?
Take the 2-minute tour
×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.
To see how to get a checkbox onto the dialog of a Python script tool try using some test code like this:
Then when you add this script as a tool you will need two Parameters, the first of Data Type String and the second of Data Type Boolean. |
||||
|
A sample code for a script tool which will have a single check box. If a check box will be checked by a user, the tool will verify existance of a specified data file.
Remember to add a tool parameter of Boolean data type when creating a new script tool in ArcGIS Desktop application. This parameter will be automatically shown as a check box when user runs the tool. |
|||||||||
|