我在线面建立了一个创建直线的程序 部知道怎么区使用何调用它
给出创建源代码:AcDbObjectId<BR>createLine()<BR>{<BR> AcGePoint3d startPt(4.0,2.0,0.0);<BR> AcGePoint3d endPt(10.0,7.0,0.0);<BR> AcDbLine *pLine=new AcDbLine(startPt,endPt);<BR> AcDbBlockTable *pBlockTable;<BR> acdbHostApplicationServices()->workingDatabase()<BR> ->getSymbolTable(pBlockTable,AcDb::kForRead);<BR> AcDbBlockTableRecord *pBlockTableRecord;<BR> pBlockTable->getAt(ACDB_MODEL_SPACE,pBlockTableRecord,<BR> AcDb::kForWrite);<BR> pBlockTable->close();<BR> AcDbObjectId lineId;<BR> pBlockTableRecord->appendAcDbEntity(lineId,pLine);<BR> pBlockTableRecord->close();<BR> pLine->close();<BR> return lineId;<BR>}
那位知道怎么在主函数中区调用它 并能在CAD中画出一条直线.
页:
[1]