
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi All,
I am trying to filter all the viewports that I have inside a Revit project (used or not used). So far I have written something like this (It is in Python and it is based on the follwoing link https://forums.autodesk.com/t5/revit-api-forum/filtering-viewport-types/m-p/9287944#M44258:
viewport_list = []
viewports = FilteredElementCollector(doc).OfClass(ElementType)
for element in viewports:
if element.FamilyName == 'Viewport':
viewport_list.append(element)
When I try to print the name of these viewports it gives me the actuall system family name which is Viewport!:
for vp in viewport_list:
print(vp.FamilyName)
So the only thing printed is Viewport.
So the thing is I want to find an specific viewport with the name "XXXX" . But i don't know how to do that cause I can't get access to the names of the viewports!
Any help would be much appreciated.
Thanks,
Dave
Solved! Go to Solution.