Activate Layer and Print to PDF

Below is my original post in EPDM forum.  I was advised to post in this forum.  Can anyone help?

Hello all,

Our vault has 4 main folders, engineering, production, quality, and sales. Within each main folder, the sub-folder structure is the same/very similiar. The idea is to create a task that would output a PDF using a SolidWorks drawing found in the engineering folder and place it in the same named folder in the quality folder. There are multiple folders with the same name due to sub-folder structure.  I am trying to output a PDF during a transition that would carry over metadata, save the PDF to the correspoding sub-folder structure, and activate a certain layer (always has the same name).  I believe this can be done using Advanced Scripting Options under Tasks (Output to PDF). I do not know much about VBA scripting other than cutting and pasting.  Any help would be appreciated.

Thanks

SolidworksApi macros