Request

Response

    ElementDataModel.InstantiateDesign method

    Instantiates a design in an element. This allows reusing the same design (geometry + model hierarchy) across multiple elements. Examples: Reuse the same design in multiple elements, create a sub-assembly from a part, or create multiple instances of a block, etc.

    public void InstantiateDesign(IDesign designReference, IElement instantiatingElement)
    
    parameterdescription
    designReference A reference to the IDesign that represents the geometry and model hierarchy that needs to be instantiated.
    instantiatingElement The IElement where this design needs to be instantiated.

    Exceptions

    exceptioncondition
    ArgumentNullException Thrown when designReference or instantiatingElement is null, or when designReference refers to a deleted or missing design.
    InvalidOperationException Thrown when the element already contains a design.
    ArgumentException Thrown when instantiatingElement is not an SDK-provided IElement implementation.
    CyclicDesignReferenceException Thrown when instantiating the design would create a cyclic design reference.

    See Also