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

not that kind of class error
not that kind of class error
in processing block entities, my code encounters some blocks that cause a
not that kind of class
error, when it tries to call the explodetoblock(oddbblocktablerecordptr) function. on further analysis, the error is
object of class acdbrotateddimension can't be cast to oddbdimensionrecomputepe (probably appropriate protocol extension is not registered)
how can this be fixed?
the code snippet in question is
oddbblockreferenceptr pblock = pent;
oddbobjectid idowner = pent->ownerid();
if (!idowner.isnull()) {
// the exploded stuff will be appended to owner of entity being exploded
oddbblocktablerecordptr pbtr = oddbblocktablerecord::cast(idowner.openobject(oddb ::kforwrite));
if (!pbtr.isnull()) {
if(!pinsert->isunloaded() && !pinsert->isfromexternalreference())
pent->explodetoblock(pbtr);
}
}
just a guess, but have you linked to the recomputedimblock modules?
i had hooked in the recomputedimblock modules, following the instructions from an earlier thread. it still didn't work, but i didn't notice that the error message had changed to not being able to find recomputedimblock_2.04_8.drx. after adding that to the relevant directory, it is now working.
thanks very much.
yang686526离线中   回复时引用此帖
GDT自动化论坛(仅游客可见)