Get Level from Wall's Top Constraint Parameter

Get Level from Wall's Top Constraint Parameter

Anonymous
Not applicable
901 Views
1 Reply
Message 1 of 2

Get Level from Wall's Top Constraint Parameter

Anonymous
Not applicable

Hi Guys,

 

I am am trying to retrieve the Level object from a Wall's Top Constrain parameter. But I am not sure if this is posssible. Although having a look in the Revit Lookup I can get to that data. 

 

A.PNGB.PNG

 

Do you guys know if this is achiavable?

 

Here is my short method for know, (dont pay attention to the name of and the fact that is returning void)

 

   private void FilterDependantWallsOnHeight(double heightFilter, List<Wall> walls)
        {
            for (int i = 0; i < walls.Count; i++)
            {
                Parameter TopConstrain = walls[i].get_Parameter(BuiltInParameter.WALL_HEIGHT_TYPE);

               ElementId id= TopConstrain.AsElementId();
                
            }
        }

Thanks, Nicholas

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

jeremytammik
Autodesk
Autodesk

Everything that RevitLookup does, you can do in your add-in too.

   

Your method looks like a good start.

 

Keep going  🙂

 



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

0 Likes