Active View with Area Plan


Hello all,

I am trying to gather all grids in the active view (an Area Plan). My script works fine with Floor plans but fails when the Active view is an Area Plan. Anyone have an Idea?

Similar issue:


Originally reported here:

And solved here:

So this should work in Dynamo 2.0 … :slight_smile:


Hi @Steven

Or else you can just write a few lines of python to get it worked in Dynamo1.3.2 :slight_smile:

import clr
from Autodesk.Revit.DB import *

import RevitServices
from RevitServices.Persistence import DocumentManager

view = UnwrapElement(IN[0])

doc = DocumentManager.Instance.CurrentDBDocument

coll = FilteredElementCollector(doc, view.Id)
filt = ElementCategoryFilter(BuiltInCategory.OST_Grids)
grids = coll.WherePasses(filt).ToElements()

#Assign your output to the OUT variable
OUT = grids


Thanks Andreas,

I was looking around but could not find anything.


Thanks Kulkul,

That worked perfectly.


@Steven Please mark the post as solved. You’re welcome!


Sorry I thought I clicked it. :slight_smile:


The equivalent node in springs is called “Collector.ElementsInView” :wink: