Message 1 of 3
Revit API Connect Ducts with fitting

Not applicable
08-16-2017
06:12 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello, I have 2 Ducts and I want to connect them with a fitting. Howcan I do that. I'am searching for that since a week but I couldn't find anything.
I use this code to get the connectorset but I don't understand how to get the Connectors from it:
public static ConnectorSet GetConnectors(Element element) { if (element == null) return null; FamilyInstance fi = element as FamilyInstance; if (fi != null && fi.MEPModel != null) { return fi.MEPModel.ConnectorManager.Connectors; } MEPSystem system = element as MEPSystem; if (system != null) { return system.ConnectorManager.Connectors; } MEPCurve duct = element as MEPCurve; if (duct != null) { return duct.ConnectorManager.Connectors; } return null; }
Can anyone provide me some help with that?