Can't Set Parameters for a Script Tool

3062
15
10-27-2017 01:28 PM
JoeBorgione
MVP Emeritus

The setting:  ArcGIS 10.5.1, Windows 10 64bit os

I'd like to explore developing a script tool but have run into a road block.  I thought it was just me being a bone-head, but for once it's not. (I know, right?!)  

I downloaded a zipped toolbox and script tool from an ESRI page, just to see what's up with the procedure.  Toolbox works, as does the script itself. But...

Then I try to add a script to that same toolbox, using the same script (renamed to myScript.py) and when I get to the step where I am to define the parameters, the form will not accept anything I add.  I type in a value in the the display name column and when I tab to or click on the data type column, the name disappears.  I sent the script to a team mate of mine and he is able to to get it to work just fine.

I didn't find anything about this with a search, but I'm wondering if anyone else has come across this problem. 

That should just about do it....
0 Kudos
15 Replies
DanPatterson_Retired
MVP Emeritus

reboot?

script and toolbox in same folder?

its friday

JoeBorgione
MVP Emeritus

I'll take Friday for $100 please....

That should just about do it....
RebeccaStrauch__GISP
MVP Emeritus

If might help if you either attach the tool/script you downloaded or include the URL of what you downloaded.  Then others could try to see if they are getting the same thing. 

How are you adding the new tool script?  Are you right-clicking on a toolbox you created (ie. that you have read/write access to) and then choosing "Add-> Script" ?  Or are you adding it in another way?  Are they compatible versions?  Just a few things to check.  I add my own python scripts to custom toolbars all the time and have not had any issues with the Paramater tab....but I'm still on 10.3.1 for development.

JoeBorgione
MVP Emeritus

Thanks Rebecca-  it doesn't matter what script I try to use, where the script is located or where the toolbox is located. The dialog simply fails on my computer.  For example, I just downloaded a script and toolbox from : http://www.arcgis.com/home/item.html?id=e638afe0695a4ad38388cb8d9b350446 .  I've unzipped it to my desktop.  Here is a screen cap of an ArcCatalog window with  a windows explorer window on top:

Then I start the Add Script Dialog in ArcCatalog by right clicking on MyToolBox and select Add Script:

Followed by adding the script file in the directory shown above:

But when I get to the third and final pane if the Add Script dialog, if/when I add text to the Display Name column, it automagically disappears when I tab or mouse click into the Data Type column

I opened a case with Tech Support earlier this morning, a scant 5 hours ago...

rastrauch

That should just about do it....
0 Kudos
RebeccaStrauch__GISP
MVP Emeritus

Have you tried the standard Resetting your ArcGIS application profile‌ yet?

I just downloaded, unzipped and tried to add a parameter to the downloaded Toolbox/Tool, and didn't have an issue.

Again, check that you have it in a location that has read/write access, but it don't seem to be a problem with the Tool. Although in production I'm not on 10.5.xz yet, I have a machine setup and tested there....worked without an issue too.  fwiw.

0 Kudos
DanPatterson_Retired
MVP Emeritus

try it in a real folder... my students do this unzip to desktop for many things assuming they are going to save some time... it very often fails...

RebeccaStrauch__GISP
MVP Emeritus

Good thought and good practice.  Although I just tested on my 10.3.1 and it behaved.  fwiw.

DanPatterson_Retired
MVP Emeritus

but the next time you try something... it is a just don't do, because when you need it to work the most, it will fail.  I have had students sitting beside one another trying to open up projects unzipped to desktop... it will work for one and not the other... go figure

0 Kudos
JoeBorgione
MVP Emeritus

Did that last friday before and after the reboot....  

That should just about do it....
0 Kudos