wblockCloneObjects returns eInvalidInput

wblockCloneObjects returns eInvalidInput

Anonymous
Not applicable
640 Views
0 Replies
Message 1 of 1

wblockCloneObjects returns eInvalidInput

Anonymous
Not applicable
	AcDbObjectId idModelSpace = AcDbSymbolUtilities::servicesPtr()->blockModelSpaceId(pTargetDb);
	AcDbIdMapping idMap;
	es = pTempDb->wblockCloneObjects(idsNeedClone, idModelSpace, idMap, AcDb::kDrcIgnore);
	if (Acad::eOk != es) acutPrintf(TEXT("\n>>> err006: %s"), acadErrorStatusText(es));

I use this method to clone entities from the current file to another file. But it return eInvalidInput error. But it appears just for some source files.

In the API file, I find this

Possible return value are as follows:

Various open errors -- if the owner cannot be opened for kForWrite. 
eInvalidOwnerObject -- if the owner is not one of the three valid types of object. 
eInvalidInput -- if the drc is not one of the four valid types, or not the same on multiple calls. 
eWrongDatabase -- if the owners are not from the same database 
eIllegalEntityType -- if the objects being cloned do not accept the owner passed in. 

So, whiat's the problem? May be, It's the problem of the idsNeedClone? 

0 Likes
641 Views
0 Replies
Replies (0)