ObjectARX
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Reading DWG

0 REPLIES 0
Reply
Message 1 of 1
Anonymous
164 Views, 0 Replies

Reading DWG

Hello members,

What I want to know is the differences between reading in current drawing (curDoc()->database()) and reading file as offline using ;
AcDbDatabase *pDb = new AcDbDatabase(Adesk::kFalse);
pDb->readDwgFile(DWGNameToOpen);

AcDbBlockTable *pBlkTbl;
pDb->getSymbolTable(pBlkTbl, AcDb::kForRead);

AcDbBlockTableRecord *pBlkTblRcd;
pBlkTbl->getAt(ACDB_MODEL_SPACE, pBlkTblRcd, AcDb::kForWrite);

pBlkTbl->close();
AcDbBlockTableRecordIterator *pBlkTblRcdItr;
pBlkTblRcd->newIterator(pBlkTblRcdItr);

for (pBlkTblRcdItr->start(); !pBlkTblRcdItr->done(); BlkTblRcdItr->step()) { ...}

I found that the number of etities of reading offline is 2 or 3 times bigger than reading in cuurent doc.

I uses ssget() by filter only "X" in current doc.
How can I get the same result in offline reading.
I tested it using ;
Adesk::Boolean pErasing=pObj->isErased();
if ((pErasing == Adesk::kFalse) && (pEnt->visibility() == AcDb::kVisible)) { .. }
However, I falied to get the correct result.

I would appreciate it if someone advise.

ChangHoon Lee
0 REPLIES 0

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost