Trying to find the Element ID of a shared parameter

Trying to find the Element ID of a shared parameter

ssw9UZNL
Advocate Advocate
317 Views
1 Reply
Message 1 of 2

Trying to find the Element ID of a shared parameter

ssw9UZNL
Advocate
Advocate

Hello,

Can someone please tell me how I can get the element ID of a shared parameter.

I have managed to find all the curtain panels in my project and isolate one, I have then been able to found all the possible paramters for that curtain panel and I have then married it up to the one I want using:

 

Name = param.Definition.Name

 

But when I try and use ElementId = param.AsElementId();

 

It return a value of -1 but I want the 6 digit code that usually comes.

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

naveen.kumar.t
Autodesk Support
Autodesk Support

Hi @ssw9UZNL ,

 

Have a look at this below link

https://forums.autodesk.com/t5/revit-api-forum/element-id-of-shared-parameter/td-p/7473547 


Naveen Kumar T
Developer Technical Services
Autodesk Developer Network

0 Likes