This document will walk you through how to create a custom print service developed by @TanuHoque that will print dynamic text from feature layers.
Publishing the Print Service
1. Create a layout in ArcGIS Pro
2. Add your Map Frame and any other elements. Note: If there is only one map frame on the layout, it will be used to reference the web map by default. If there is more than one map frame on the layout, name the map frame to be used as WEBMAP_MAP_FRAME.
3. Add dynamic text by going to Insert > Dynamic Text. Scroll down to Table Attribute > Value

4. Select the Map Frame, the layer for Table, set Query to Visible Rows, and specify the Field that will display the dynamic text. Optionally, specify a Delimiter

5. Draw a rectangle in the layout where you would like the dynamic text to be placed

6. In the Element pane, click the Text View button

7. Change the field to all lower case


8. Once all the dynamic text has been added, remove the layer(s) used to create the dynamic text from the Map Frame

9. After the layer(s) have been removed, go to Share tab > Layout File and export the .pagx to a folder
10. In the attached Dynamic Printing.tbx, open the Export Web Map tool. Specify the Format, choose the folder you exported the .pagx file to in step 9 for Layout Templates Folder, choose a Layout Template, and then Run the tool

11. In the DynamicPrintService.tbx, open the Get Layout Templates Info tool. Choose the folder you exported the .pagx file to in step 9 for Layout Templates Folder and then Run the tool

12. Click on the Analysis tab > History to open the History pane

13. Before proceeding make sure ArcGIS Pro is connected to your ArcGIS Enterprise organization. Right-click on the Export Web Map tool > Share As > Share Web Tool

14. Specify a Name for the print service. Under Data, choose the option Reference registered data. Optionally, specify a Portal Folder and share the service (i.e. to your Organization)

15. Click Configuration tab. For Execution Mode specify Synchronous and set the Message Level to Info

16. Click the Content tab. Click the Add Tool and select the Get Layout Templates Info tool

17. Analyze and Publish the service
Using the Print Service
The next section will walk you through how to configure the custom print service using ArcGIS Enterprise Web AppBuilder
1. Create a web map using a feature layer. If you are working with a Map Service, i.e. https://ags.esri.com/server/rest/services/ConnectionInfo/MapServer, be sure to add the layer to your web map as a feature layer. To do this, in the web map choose Add > Layer From Web > paste in the URL with the index value. Ex: https://ags.esri.com/server/rest/services/ConnectionInfo/MapServer/0
2. Save the Web Map
3. Create a Web Application using Web AppBuilder and choose the web map you just created that contains the feature layer
4. Add the Print widget to your Web Application
5. For the Service URL, specify the path to your print service including the GPServer/Export%20Web%Map. Ex: https://jake2.esri.com/arcgis/rest/services/Dynamic_Print_Service/GPServer/Export%20Web%20Map
Optionally, specify a Default title, Default author, Default copyright, Default format, and Default Layout

6. The custom print service will print dynamic text for all visible features. If you want to limit the extent to a particular feature, you can add the Filter widget and filter based on a unique attribute.
7. Open the Print widget, choose the Layout and Format, and then click Print

Here is an example of an output PDF created with the dynamic text on the left:
