IPropertyManager.GetPropertyDefinitions not working in Vault 2017

IPropertyManager.GetPropertyDefinitions not working in Vault 2017

KarlR.J.Wehr
Enthusiast Enthusiast
651 Views
1 Reply
Message 1 of 2

IPropertyManager.GetPropertyDefinitions not working in Vault 2017

KarlR.J.Wehr
Enthusiast
Enthusiast

Hi,

 

since upgrading to Vault R2017 the function GetPropertyDefinitions in Vault.Services.Connection.IPropertyManager is not working anymore.

I am using it in a Vault Extension. Calling the function results in a System.NullReferenceException exception.

 

This is the code i use:

 

Vault.Services.Connection.IPropertyManager pm = m_conn.PropertyManager;

Vault.Currency.Properties.PropertyDefinitionDictionary pdefs;

pdefs = pm.GetPropertyDefinitions

  (

  Vault.Currency.Entities.EntityClassIds.Files,

  null

  Vault.Currency.Properties.PropertyDefinitionFilter.IncludeAll

  );

 

 

In the stack trace i can see that the error occurs here:

    Autodesk.DataManagement.Client.Framework.Vault.Services.Connection.Implementation.PropertyManager.<>c__DisplayClass8_0.<GetPropertyDefinitions>b__0(PropertyDefinitionToEntityClassAssociation f)

 

 

 

The same code is working in a stand alone application but running in a Vault Extension it throws the above error.

 

Can anybody help me?

 

Karl

0 Likes
652 Views
1 Reply
Reply (1)
Message 2 of 2

wayne.brill
Collaborator
Collaborator

Hi Karl,

 

Your code is working ok for me using the HelloWorld SDK sample. Below is a screenshot. Can you try this in HelloWorld? If your code does not work in HelloWorld either can you tell me about your system? What is the bitness and locale?

 

Also does using a different Vault make a difference?

 

 

Debug_PropertyManager_WB.jpg

 

 

Thanks,

Wayne



Wayne Brill
Developer Technical Services
Autodesk Developer Network

0 Likes