2 Replies Latest reply on Oct 19, 2015 10:36 AM by Craig Burg

    Use Create PDF to Mirror Vault Files without C:\Vault in the Path

    Craig Burg

      As the first step of implementation, we will be use the Create PDF Add-In to create drawing files outside of the Vault on another network drive ("N:\").  We would like to keep the same directory structure outside of the vault as inside on the "mirror".  The Create PDF Task includes specification of the Default Path, but this always includes the local drive name.  These essentially become additional directories on the target N:\ drive.  The example under default path is "N:\C:\Vault\Part.pdf". 

       

      When generated, the "C" and "Vault" directories are not needed and are confusing for our users outside of engineering.  We would like to keep the path without the root drive or vault name. 

       

      KB solution S-061104 describes some modifications that may be similar, but I have been unsuccessful in modifying Advanced Scripting Options to date. 

       

      Any help would be appreciated. 

        • Re: Use Create PDF to Mirror Vault Files without C:\Vault in the Path
          Tyler Johnson

          In the output file details change the default output path to source location so it's trying to put the file in C:\Vault\Somefolder\somfile.pdf.

           

          Then in the script modify the variable "convFileName" to change the C:\ to N:\ after this line:

           

              ' Build destination filenames

              convFileName = "[OutputPath]"

              convFileName = Replace(convFileName, "C:\", "N:\") ' <-- Add this line

           

          If you do this you will want to make a copy of the task because that script modification will make the task always do this so it becomes useless for any other function.

           

          Also I believe i read once that script modifications are reset if the add-in is updated, or maybe it was even just epdm?  In any case you'll want to make note of this somewhere so you know to modify it again if need be.

           

          I have not tested this.  If it doesn't work follow that variable around the code and see what changes it and maybe just set the convFileNameTemp directly prior to the swExtension.SaveAs.  Just make sure you do so in every applicable spot.

            • Re: Use Create PDF to Mirror Vault Files without C:\Vault in the Path
              Craig Burg

              Tyler,

              Thank you!  This worked perfectly.  I used in the following exact context:

               

              convFileName = Replace(convFileName, "C:\Vault\", "N:\")

               

              This replicates the structure of our vault in the N: drive we call "Product Documentation".  Our workflow will create a .pdf of any drawings in the Product Documentation drive when state becomes "Production Released". 

               

              This gives our users without access to the vault easy access to prints to reference.  At a later stage the hope is to have Viewer licences.  Until then we have a workable solution.

               

              Thank you Tyler.