查看单个帖子
旧 2009-05-04, 06:29 PM   #1
yang686526
高级会员
 
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
yang686526 向着好的方向发展
默认 【转帖】crash in oddbhatchgetpattern

crash in oddbhatch::getpattern
crash in oddbhatch::getpattern
hello forum,
if i run the following code onto the attached dwg, i get a crash in getpattern.
my version is dwgdirect 2.4.1. could you explain me what is happening please ?
code:
blockrecord = database->getpaperspaceid().safeopenobject() ;
objectiterator = blockrecord->newiterator();
for(objectiterator->start() ; objectiterator->done() == false ; objectiterator->step())
{
oddbobjectptr obj = objectiterator->objectid().safeopenobject() ;
if(obj->iskindof(oddbhatch::desc()))
{
oddbhatchptr hatch = oddbhatch::cast(obj) ;
odhatchpattern pattern = hatch->getpattern() ;
}
}attached files
you can reproduce this exception in odamfcappdll 2.5.2 by pasting my piece of code in codamfcappdoc:nopendocument and opening crashhatch.dwg.
see the attached jpeg.
attached images (188.1 kb, 5 views)

i entered defect 5089 for this problem and fixed it.
the paper layout in the drawing contains no viewports (and where is no overall viewport too).
sergey slezkin
yang686526离线中   回复时引用此帖
GDT自动化论坛(仅游客可见)