I’ve put together a basic script (see image 2) that reads an excel file to create a number of sheets and assign view templates to them.
This is working fine, however, by default the newly generated floor plans are of a specific floor plan type. The resulting issue is that sheets are located in the incorrect subfolder within the project browser, as the office standard groups plans by floor plan type (see image 1).
I need to change the newly generated floor plans from the system family type ‘A1 - DOCUMENTATION FLOOR PLANS (INDIVIDUAL UNITS)’ to ‘A1 - DOCUMENTATION FLOOR PLANS’ so that they will then display in the correct subfolder.
I’ve had an extensive look online but couldn’t figure out a way to assign a system family type such as a floor plan type as it’s different to assigning a family type parameter. Image 3 shows two nodes I’ve tried to use but don’t seem to be working…
Has anybody done this before? If so could you please point me in the right direction? Any helpful advice or links to similar cases would be greatly appreciated.
Thanks in advance!
following this thread…I am also lost here. Facing the same problem
You can set the ViewFamilyType by using Element.SetParameterByName like this:
I don’t know if there’s any nodes for collecting ViewFamilyTypes in the document, but here i used a simple python script, and then manually pick the desired type:
#Import the Revit API
from Autodesk.Revit.DB import *
#Import DocumentManager and TransactionManager
from RevitServices.Persistence import DocumentManager
#Reference the active Document and application
doc = DocumentManager.Instance.CurrentDBDocument
#Start scripting here:
OUT = FilteredElementCollector(doc).OfClass(ViewFamilyType).ToElements()
Try the Element Types and All Elements of Type like this post. Assign View Type to Batch Plan Views
Thank you kindly for your reply. Unfortunately python is over my head at this point in time. Out of curiousity, is it simply a matter of copying your script and pasting it into a code block in dynamo? Thanks
Thanks so much for taking the time to post. The approach you suggested worked exactly as intended. I wasn’t familiar with the element types node.
Interestingly enough, while working on another script today I happened to stumble across the Rhythm node ViewFamilyTypes which saves a couple of steps by allowing one to select view family types within the active project from a dropdown list.
Thanks again for your solution.
@Revit_Noob Hope the suggestions helped you resolve your issue!
the Phyton Code worked for me. Thanks
@Revit_Noob out of curiosity - do you just copy and paste the script into a code block?
@dynamo_den copy and paste into a Phyton Script node.
Copy the script…right click on the empty screen. Type Script and select Phyton Script.
Once you have the node, right click and edit.
Erase everything and paste the script posted here.