AnsweredAssumed Answered

Task Add-in: Add "view pdf after saving" functionality

Question asked by Nick Tzallas on Aug 3, 2020
Latest reply on Aug 17, 2020 by Wayne Matus

We have recently setup the Convert to pdf task add-in in PDMPro to generate pdf's of drawing files upon state transition.

All works perfectly fine, just the default task add-in. 

 

We have a lot of legacy files from 10+ years ago, that sometimes generate blank views on certain sheets of the final pdf when the task is triggered by a transition

However after that, if the pdf convert task is manually triggered by the user i.e. "RMB>convert to pdf task", the views are generated correctly

I have looked at the old knowledge base article S-065824 and confirmed that the task has the code to run full view and auto-updates all views etc. (as expected, we are running 2020 and this is a fix that was applied after 2015, so it's baked in out of the box since then)

 

As an intermediate solution, in order to help my users inspect all the pdfs generated during the transition I would like to add to the task a "View pdf after saving" functionality. Namely:

 

Additional new functionality in red

  1. User changes state via transition
  2. Transition change triggers action to run PDF convert task
  3. Once convert task completes successfully (or during, whichever), the default PDF handler (adobe acrobat) opens all pdf's created during that particular task run for the user to inspect and see if any one drawing needs a manual pdf re-generation

 

I have found the following dead post from 2016  save pdf and open  but it seems there was never a solution provided.

 

Does anyone have any code snippet I could add to the custom scripting of the task add-in?

 

Running:

SW 2020 SP3.0

PDM 2020 SP2.0

Outcomes