Orchid Package Help

I am trying to set text font parameters in family and saved them in the directory. I am relying heavily on Orchid packages nodes but having no luck.

the Error message is telling

“Warning: FamilyDocument.SetParameterByName expects argument type(s) (Document, string, string, var), but was called with (Autodesk.Revit.DB.Document, Autodesk.Revit.DB.FamilyType, string, string).”

I will post the screenshot of my graph.

@erfajo will you please help? I appreciate in advance!

Orchid Error.dyn (20.7 KB)

I believe you are missing that the FamilyType input takes strings, not types.
You might be right that I should make it accept FamilyTypes as well, but I coded it with string input because I had an idea that users might want to select which family types to get/set, for that I developed the FamilyDocument.Name node so one knew which family types were used.

Also please notice that “default” family type must contain a “name”. If it doesn’t have a proper name, then use the FamilyDocument.CreateFamilyType before FamilyDocument.Name.

Orchid Error.dyn (24.8 KB) -> dynamo 2.0 format

1 Like

Wow @erfajo, Thank you for your fast reply!

I went through your comment and still having some warnings.

I took your advice and added the missing <<FamilyDocument.Name>> and <<FamilyDocument.CreateFamilyType>> but I guess I did something wrong agian :frowning: .

when I connected <<FamilyDocument.AllFamilyType>> with <<FamilyDocument.Name>>, FamilyDocument.Name node is showing

““Warning: FamilyDocument.Name operation failed.
Please run this command in a family document.””

And <<Family.Document.SetParameterByName>> node is showing,

““Warning: FamilyDocument.SetParameterByName operation failed.
The referenced object is not valid, possibly because it has been deleted from the database, or its creation was undone.””

After that, the <<Document.Close>> Node is showing

““Warning: Document.Close operation failed.””

and giving me duplicates of the .rfa in the directory.


I thought/wanted the .rfa will save/overwrite instead of creating duplicates.

Again I will upload my graph again but this one is under dynamo 1.3 .

And again I very appreciate your help! Thank you so much!!

Change fonts in Family.dyn (10.3 KB)

Sorry for my absence,

I think you can solve this by removing the “name” feed to the “FamilyDocument.CreateFamilyType”, then it will make the family name as the default name.

However, the warning indicates that you have runned the graph with an error once, and then tried to rerun it… by doing this you try to reopen the families, but they are not closed from the former “run”… if you fail in running these graphs, you need to close Revit and reopen Revit. Otherwise is familydocuments open in the background!

Change fonts in Family.dyn (9.8 KB) -> dynamo 1.3 format

When saving Revit allways makes backup files… thats just how it is :slight_smile:


Not at all! @erfajo!

I see this method working really well! Life Savior!

Appreciate your help!! :grinning::grinning::grinning:

1 Like

hi everyone,
i want to do the exact same thing but somethings going wrong.
In my example, i have 2 famillys with 2 parameters.
And it’s seems that the script runs 2 times.
It’s maybe the lacing or something but i tried multiple combinaison and i can’t find the right.