Start a new topic

list of Property mappings in vault

 Hello


is there a way to get the list of vault property mappings against the inventor iproperties and autocad titleblock properties via Powervault

(Vault: Tools -> Vault Settings -> Property Definitions -> Mapping)

Now you have to open each UDP manually to verify if there is something wrong for example


Thanks

Patrick


Hello Patrick,

powerVault gives you access to the Vault properties only. There can be cases where it is more convenient to access the IProperties or DWG properties. In those cases you have to access them via their respective application API. 


In the case of Inventor you can access the API through the $openResult.Application.Instance object after you opened a file with the Open-Document commandlet. In case of AutoCAD it is a bit more complicated and requires quite a bit of know how. We describe a workflow how to access the AutoCAD API in this article. http://support.coolorange.com/solution/articles/22000206915-how-to-use-autocad-in-powerjobs


From your post I understand that you want to compare the values in the Vault properties to those in the CAD properties. If that is the case you should let Vault handle this during state changes. There is no need to implement extra code for this.


Best regards,

Thomas


----------------------------

Thomas Rossmeisl

Technical Support

 

Please mark your thread as solved if your question was answered

Hi Patrick, this intrigued me a bit, so I gave a look to the Vault API. As Thomas stated, powerVault does not expose "admin like" command-lets, so you can easily manage files and other objects, but if I get you right, then you like to have a simple overview of all mappings that have been done, right?


I started Fiddler with vapiTrace and tried to figure out how Vault shows the mapping with the admin part, as you pointed out. The calls looks like this: 

$vaultCfg = $vault.AdminService.GetServerConfiguration()
$propDefs = $vault.PropertyService.GetPropertyDefinitionInfosByEntityClassId("",$null)

 What you get back, is a list of all supported applications, and all properties with according information, including the mapping. However, the mapping part is not easily readable. If you take one property and look into the $propDef.EntClassCtntSrcPropCfgArray, there you'll find all the mappings. However, my Title property has 6 mappings in Vault, and the list from the API shows me 14. Many of them look just redundant. 

It gets worst, as in the mapping you don't see the application ID (CtntSrchId) which can be looked up from the $vaultCfg.CtntSrcArray, and the according property name, which is a so called moniker, an alias for the property. As an example, you'll get something like this 2!{F29F85E0-4FF9-1068-AB91-08002B27B3D9}!nvarchar, where the first number is the index of the property, the GUID is the section within the property array of the application. So, figuring out what this property is, it's a bit complex. You can use the apprentice server, open an Inventor file and look for such properties. Alternatively, we discovered that when you do a BCP export of your Vault, you'll get a PropDefswrapper.xml which contains the definition of mapping, and there you'll find the name of the property for the given GUID. There is no API we could find that resolves the GUID. Somehow the information must be in Vault, otherwise BCP could not write them out the Vault UI would not show them. But by monitoring the Vault client-server communication, I was not able to find the last piece that translates the GUID into something readable.


I hope this helps somehow.


ciao

marco

----------------------

Please mark your thread as solved if your question was answered

Login or Signup to post a comment