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

block attribute display problem
block attribute display problem
hello, please see the attached dwg file and the attached png file for reference. i have a dwg file with 3 dynamic block insertions. the first one displays fine, the 2 others have their attributes rotated slightly. i tried viewing this in the 2.6 odamfcapp but it is crashing. can you please see if this displays correctly in the latest version and if, in fact, it is a defect in 2.4? i don't see how our code could be causing the rotation.
thank you,
chad
attached images
there seems to be a bug in version 2.4 - it should display this drawing like autocad 2007.
there are broken multiline annotative attributes in the drawing. they are broken in a way that we've never met before (and not expecting), which causes the crash of 2.5.1 - 2.7.0 versions. this bug will be fixed in version 2.7.1, but we'll behave like acad 2008: broken attributes won't be displayed.
vladimir
thank you for that information. i have one more question about this drawing:
is it possible to extract the "visibility state" text of the dynamic block inserts using dwgdirect?
thanks,
chad
quote:
originally posted by cames@newforma.com
is it possible to extract the "visibility state" text of the dynamic block inserts using dwgdirect?
you may use oddbdynblockreference interface, to access dynamic properties.
see examples\exdynamicblocks\exdynamicblocksmodule.cpp , listpropertiescmd::execute()
vladimir
thank you very much for the quick reply.
chad
hello,
i am getting the error below (which throws an exception) when i make the call to getblockproperties. looks like a proxy object may be the root cause. any idea what the problem is?
thanks,
chad
dwgadapter.dll!defaultassert(const char * expr=0x0d3a7354, const char * filename=0x0d3a7328, int nline=791) line 54 c++
dwgadapter.dll!odassert(const char * expresssion=0x0d3a7354, const char * filename=0x0d3a7328, int nlineno=791) line 79 + 0x12 bytes c++
dwgadapter.dll!odqueryximpl<oddbproxyobject,oddbob ject>(const oddbproxyobject * pthis=0x0df4a0d0, const odrxclass * pclass=0x00000000) line 791 + 0x1a bytes c++
dwgadapter.dll!oddbproxyobject::queryx(const odrxclass * pclass=0x00000000) line 11 + 0x14 bytes c++
dwgadapter.dll!oddbevalgraph::cast(const odrxobject * pobj=0x0df4a0d0) line 109 + 0x26 bytes c++
dwgadapter.dll!oddbevalgraph::getgraph(const oddbobject * pobj=0x0df5e440, const odstring & key={...}, oddb:penmode mode=kforread) line 234 + 0x3a bytes c++
dwgadapter.dll!oddbdynblockreference::getblockprop erties(odarray<odsmartptr<oddbdynblockreferencepro perty>,odplainobjectsallocator<odsmartptr<oddbdynb lockreferenceproperty> > > & properties={...}) line 290 + 0x29 bytes c++
i can't reproduce that in 2.4.2
did you try the same file that is attached earlier?
vladimir
yes, i am using the same drawing file. could it be related to having the adt modules loaded?
-chad
probably "dd_dynblocks" module is not loaded.
call :drxdynamiclinker()->loadmodule(l"dd_dynblocks.drx"); after odinitialize()
vladimir
last edited by vkalinin; 25th november 2008 at 09:05 amfff">.
i am already statically linking in that module with:
odrx_declare_static_module_entry_point(dd_dynblock smodule);
...
...
...
odrx_begin_static_module_map()
...
...
odrx_define_static_application(_t("dd_dynblocks"), dd_dynblocksmodule)
...
is there a way i can verify that this module is being loaded properly?
thanks,
chad
static linking doesn't call initialization by itself, call also loadmodule()
vladimir
i'm still receiving the same error. unless you have some other suggestions, i'm going to put this off until i can get a new version of the toolkit.
thanks,
chad
i don't think new dd version will change anything.
you may check the return value of the loadmodule() call, to make sure dynamic blocks are initialized.
vladimir
yang686526离线中   回复时引用此帖
GDT自动化论坛(仅游客可见)