Configuring Output for GIS Web Tool

09-08-2020 08:31 AM
New Contributor II



I created a python script tool that exports attachments (jpegs) using the following code:



open(fileLocation + os.sep + str(rel_objectid) + "_" + Name, 'wb').write(binaryRep.tobytes())



Originally, "fileLocation" was set as arcpy.GetParameterAsText(0), routing to my temp folder. I then changed it to arcpy.env.scratchFolder and also tried ' r"C:\temp". The script tool worked with no issues in ArcGIS Pro. When exporting to WebApp Builder widget, the output is locked and grayed out where I cannot make edits. While I did check the option to allow for export of these image attachments, held in a tableview or dbf, the tool executes but does not return output (the output tab in the widget is blank). Is there an issue with the code itself, as it's intended to write locally? How can I properly configure a user-defined output parameter that will run successfully in Pro so I can upload to my Portal?

Any insight is appreciated.


Thank you

0 Kudos
1 Reply
New Contributor III

I'm trying to find an answer for a similar question and think it might be here: 

0 Kudos