DatabaseInsert(String, String, Database, Boolean) Method

Copies the content of a specified database to this database.

Namespace: Teigha.DatabaseServices
Assembly: TD_Mgd (in TD_Mgd.dll) Version: 24.2.0.0
Syntax
public ObjectId Insert(
        string sourceBlockName,
        string destinationBlockName,
        Database dataBase,
        bool preserveSourceDatabase
)

Parameters

sourceBlockName  String
[in] Name of the block table record in the source database.
destinationBlockName  String
[in] Name for the newly created block table record.
dataBase  Database
[in] Source database to copy data from.
preserveSourceDatabase  Boolean
[in] Flag that specifies whether the source database is left unchanged.

Return Value

ObjectId
Returns the object ID for the new block table record created by this method.
Remarks
Unlike the wblockCloneObjects() method, insert() also copies the sortens table. While copying duplicate objects, names are ignored; a destination object that has the same name as the source object is rewritten by the source one. All entities in the block table record specified by sourceBlockName in the source database are copied into the new destinationBlockName. Contents of layout blocks are copied only if sourceBlockName is a layout block name. You should delete the source database either immediately or at least before the destination database is deleted.
See Also

©  Bricsys NV. All rights reserved.