How to Get the Currently OPEN Family Document (Orchid)?

My goal is to add some shared params into an OPEN family document. I don’t want to open in background and save as that may end up with families from an earlier version of Revit being saved over by a newer version. And we all know how that goes for the older version of Revit. But I digress…

I’m using the Orchid SharedParameter.Add and it wants an Orchid.RevitProject.Common.Document, which I assume is only attained by using an Orchid node to open an rfa in the background.

The Document.Current node gives a Revit.Application.Document element and the Orchid node doesn’t like that.
The archilab Current Document node returns Autodesk.Revit.DB.Document, and it doesn’t want that either! So picky! :smiley:

Is there a way to get the currently open family document translated to an orchid document?


Nevermind. There’s an Orchid node for that. Document.ToOrchidType
Translates a Revit document to an Orchid document.


Also, for reference, there was quite a bit of discussion (and changes) for this recently.

Rhythm will be updated soon to pass the Revit.Application.Document as well.


Ah, excellent. Thanks!

1 Like