|
static void EraseIds(AcDbObjectIdArray idArr)
{
if(idArr == NULL || idArr.length() == 0)
{
return;
}
for(int i = 0;i < idArr.length(); i++)
{
AcDbEntity* pDel = NULL;
if(Acad::eOk != acdbOpenObject(pDel,idArr.at(i),AcDb::OpenMode::kForWrite))
{
continue;
}
if(Acad::eOk != pDel->erase())
{
acutPrintf(_T("\n删除第%d个实体失败"),i);
}
pDel->close();
}
} |
|