ConvertWebMapToArcGISProject: How to pass in results from GP tool to the print template

604
1
07-13-2020 06:01 AM
by Anonymous User
Not applicable

Here's basically what I'm doing/needing: 
I'm creating an app in WAB where a user opens the geoprocessing tool and clicks on the map. The GP tool is a Python script that gathers information from different layers about the clicked location. The user then can download a PDF that includes the map that's displayed on the screen, a legend, and a summary of the data that the GP tool gathered.

I'm thinking that I'll have to create a custom print template and use "ConvertWebMapToArcGISProject" (maybe? maybe not? Thoughts?). But, here's where I'm stuck: I have a print template started, but I can't figure out how to reference the data gathered from the GP tool in the text box on the print layout (see the attached image). It would be dynamic text; that is, every time the GP tool runs, new data are gathered and then are printed on the layout. But, currently, dynamic text in the print layout can only reference layers and not a Python script (that I can see). Super new to Python.

Please help! I really appreciate it!

0 Kudos
1 Reply
by Anonymous User
Not applicable

Just updating on where I am, in case others are looking to do a similar thing:
I've gotten help from Esri Tech Support, and we've combined two scripts: one that completes the analysis and the one that is the print template. Works pretty slick. Did have a hard time with getting the print template part to work, so if you're trying to do something similar, it may benefit you to give Tech Support a call, because some of the things we did are different from the documentation. Also, currently we are unable to do this in ArcPro (we're still at Server 10.5.1), but I would highly suggest you use that if you can. It could make this process easier! When we upgrade the server, I'll be redoing this in Pro.

0 Kudos