Forcing system-controlled status of DWFs with PS-script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Just in case - I'm a complete newbie to both PowerShell and Vault API.
I'd like to write script that would warn Vault user about some bad things.
First thing came to my mind that worth to bother - system-controlled status for visualisation.
AFAIK there is no way to prevent user from uploading own visualisation to Inventor or AutoCAD files, right?
But let imagine that one of vault admins goal is to provide system-controlled DWF for each and every CAD-file. And believe me I'm a bit fed up to controll this manually.
Some users don't mind admins recomendations and forget to switchON "send to Job Server" option, some files can't be DWFed due to errors and thus would be removed from job-queue by Q-tools, files that were changed inside Vault usualy don't get their DWF auto-created. So there are destructive tendetion to be fixed.
I'd like my script found all CAD files that:
a) were uploaded by particular user (that, who are logged in).
b) don't have system-controlled visualisation (DWF).
c) don't have job of type "Create.DWF" and status "Pending" in the Job Queue.
I've at least two "stuck places":
1) "ALL files". Files are not in the same folder thus I wonder if I should use recursion to gather them in one list or if there some easier/faster/smarter way?
2) How to get list of Jobs from Job Server?
Thanks in advance.
PS: I'd like my script generate warning (WARNING, this database contain ## inventor documents of <username> responsibility that neither have system-controlled visualisation nor waiting their order to be DWFed. It is highly recommended that you add Create.DWF task for these files.) just before user log-out, if possible.
