Wednesday, 20 November 2019

arcgis server - Can I drop my own templates into the OTB ExportWebMap Tool?



At ArcGIS for Server 10.1, there is a print task installed by default.


Looking at the web-help, it states:



The PrintingTools service included with ArcGIS for Server references a preconfigured folder with 8 map layouts. These include basic designs in the 8.5 by 11 inches, 11 by 17 inches, A3, and A4 paper sizes in both portrait and landscape orientations. If you want to use your own layouts, you can publish your own service for printing web maps



Despite this advice, I want to confirm if it is possible to include additional templates to this Out The Box service, as opposed to having to publish a separate service.


Looking at the Service in REST, I can see these templates.
I also found the corresponding templates under:
C:\Program Files\ArcGIS\Server\Templates\ExportWebMapTemplates


If I drop a new 10.1 MXD into that folder, and restart the PrintingTools service (which now automatically clears the REST cache at 10.1), it will not pick up this new template.



enter image description here


Is there any way to configure the underlying GP service behind Export Web Map to accept new MXDs?


I did notice that if I edit one of these existing templates (e.g. add a North arrow) then these changes flow through.



Answer



With the nudge in the right direction from PolyGeo, I hunted down the model behind the service to this location:


C:\Program Files\ArcGIS\Server\ArcToolbox\Services\Printing Tools.tbx


However, from my findings, I cannot see a way to edit this model to include additional layouts. I cannot see anything in the properties of either the Layout Templates parameter or the toolbox properties to let me control this pre-defined list of MXDs.


enter image description here


I did spot an expression in the .tbx when inspecting it in a Text Editor, but manipulating this screws up the toolbox, and I do not want to be messing with text editors.





So my answer is that, based on my findings, it is not possible (let alone advisable) to add your own layouts to the OTB tool, but you need to publish a new service to consume your own new layouts.


Will be leaving this Q open for awhile, as would like someone to proove me wrong.


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...