Removing the assignment of the categories to the project / shared parameters

Removing the assignment of the categories to the project / shared parameters

shweta.deshpande
Participant Participant
348 Views
2 Replies
Message 1 of 3

Removing the assignment of the categories to the project / shared parameters

shweta.deshpande
Participant
Participant

Hello,
We want to perform the operation of removing the association of the categories with the project / shared parameters.
This can be done manually by checking or unchecking the categories.Please refer screenshot for the same.

shwetadeshpande_0-1630495106177.png

We need to do it via API.
Is there any Revit API for the same?
Please let us know.

 

0 Likes
349 Views
2 Replies
Replies (2)
Message 2 of 3

jeremy_tammik
Alumni
Alumni

I asked the development team for you.

 

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
0 Likes
Message 3 of 3

jeremy_tammik
Alumni
Alumni

I think they understood your question better than I did. They reply:

  

All of the assignments are controlled through the Binding Map,  Document.ParameterBindings:
 
   
You would find the entry for your particular parameter, get the Binding, modify the assigned Categories, and then ReInsert the modified binding.
 
   
It might be possible to also delete the parameter completely from a document by finding the corresponding ParameterElement and deleting it.    The id of that element is in the InternalDefinition for the parameter.
   
Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
0 Likes