Select to view content in your preferred language

Production Mapping - Batch Export

3041
13
11-29-2018 09:56 AM
GeoffChapman1
Emerging Contributor

We have been looking into the possibility of purchasing the production mapping extension to assist our generation of good old hard copy. However, one area I have not been able to confirm is the ability to batch export to PDF. I have found reference to this functionality in the Aviation charting extension but not explicitly in the documentation for Production Mapping. Therefore I was wondering if this was functionality available in Production Mapping out the box, is it something that we will have to automate with arcpy.mapping.

Any and all assistance much appreciated.

0 Kudos
13 Replies
GeoffChapman1
Emerging Contributor

Hi Dan,

(Apologies I'm out of the office at present so some of the following may be a little vague)

Yes, when creating our product library we selected the storage type of Database when setting up the solution, rather than the File System

Choosing a storage type for files—Help | ArcGIS Desktop Our intention was for users have to rely on checking out to control access to files without the option of manually navigating to the MXDs on the network storage and inadvertently messing things up.

However, we need at times to export the whole series to PDF. We have quite happily got up scripts that loop through a folder of MXDs and export to Production PDF, but this is only with test files held on the File System.

So far we have not found a way loop through the products in a series and export to Production PDF. As there appear to be no specific functions for traversing the production library, our best guess so far is to manually batch copy them to a folder and run the script on that with a function deleting the files after export to leave those in the Product Library as the only copy.

I was, therefore, wondering if there is a way, via arcpy, to loop through the products in a series, access the MXDs and export them without having to create local copies?

Thank you for any guidance you can give much appreciated.

0 Kudos
DanHopkins
Esri Contributor

Hi Geoff,

No need to apologize. Thank you for your response. It is clear and succinct.

I will be honest with you, I am not a programmer or scripter.

As you have discovered, the MXDs stored in the Product Library are objects that cannot be accessed using arcpy or arcpyproduction. The alternative would be to develop a UI or GP tool that would allow you to select specific MXDs or select all MXDs and check them out a file location where they could then be exported using ExportToProductionPDF. The ArcGIS for Aviation Team developed a UI called Batch Export Products that does basically that in a nutshell. However, I would suggest that you do not purchase ArcGIS for Aviation just to get access to that tool. Now I understand your question regarding Batch Export Products in your original post. 

However, there might be an alternative. In the Production Mapping toolbox. Within the Product Library toolset. There is a GP tool called Check Out File. Link to the web-help for the Check Out File GP tool is below:

Check Out File—Help | ArcGIS Desktop 

There are several parameters for this GP tool. Three of the key parameters are:

  • Product Library Workspace
  • Product Library File Path
  • Checkout path

If you could somehow figure out a way to chain this GP tool to allow you to select specific MXDs or select all MXDs in your Product Library and check them out to a file location, then you will be able to execute ExportToProductionPDF on the contents of the file location.

Regards,

Dan

0 Kudos
GeoffChapman1
Emerging Contributor

Hi Dan,

Thank you for your reply very much appreciated especially as it sent me in the direction of the solution.

As a result we have now produced a Python Toolbox that allows us to traverse the Product Library selecting the Solution and Product Class to get to the desired Series and then based upon user supplied information batch export Production PDFs of the requested products from that Series.

It does this by checking out copies to a dynamically created temp file, generating the PDF and then checking the file back in. Thus creating a scenario where by the average user does not really know that they have briefly had local copy and maintaining the integrity of the version held in the database.

Kind Regards

Geoff

0 Kudos
DanHopkins
Esri Contributor

Hi Geoff,

I am glad you were able to find a solution.

Take Care,

Dan

0 Kudos