TheSwamp
Code Red => AutoLISP (Vanilla / Visual) => Topic started by: Andrea on March 07, 2017, 09:30:04 AM
-
Hi all,..
I'm trying to find a way to detect if a dwg is a dynamic block.
I'm using ObjectDBX but I'm not able to get any information about this.
if someone can point me to any direction or suggestion it will be very appreciated.
Thank you. :)
-
Hint: "AcDbBlockRepETag"
-
Hint: "AcDbBlockRepETag"
Thank you,....Ron.
but the block is not part of the drawing.....is the drawing itself.
I'll make few tests...:)
-
In AutoCAD 2017 this works for me:
-
In AutoCAD 2017 this works for me:
wow nice...I was searching on HasExtensionDictionary...
Than kyou very much run.
-
Glad to help :)
-
I had this in my library:
(defun _dynamicblockfile
-p
( dwg
/ doc lst rtn
) )
)
)
)
"ObjectDBX.AxDbDocument"
)
)
)
)
)
)
)
)
rtn
)
-
Thank you Lee,..
i've made a lisp with Both codes of you.. :)
(setq saa (dbx_openfile
(setq fulldwg (vl-string-translate "/" "\\" (strcat _fold "\\" _dwgna)))
)
)
(if (and (_isdynamic saa)
(setq prp (lm:getvisibilityparametername vlabbl))
)
(setq bbldynlist (lm:getdynpropallowedvalues vlabbl prp))
)
the program create a list of all blocks in a folder and create a TREE list in a dialog made with ObjectDCL
showing all sub visibility option. :)
Thank you Guys.
-
You're welcome Andrea, I look forward to seeing the final result :-)
-
You're welcome Andrea, I look forward to seeing the final result :-)
not final,..but seem to work :)
the second section (rose list) contain the visibility value
-
Hi Andrea,
Cool program! ObjectDCL still is a great tool.
Not trying to hijack this topic but your question got me thinking...
I have a question, maybe you can help?
I have a folder containing about 250 dwg's.
These are all blocks... not dwg's with blocks in it but eacht dwg is 1 block itself.
Some (most) of the dwg's/blocks have dynamic properties.
Dynamic blocks created in AutoCAD are a pain in the #$$ when using them in ZWCAD.
And we use nearly 90% ZWCAD so there is the problem...
So I decided it would be better to have these dwg's stripped from dynamic properties.
But I resist on opening them all one by one...
Any idea how to "batch-excecute" this on the entire folder?
Thanks and have a nice day!
-
HERE (https://www.theswamp.org/index.php?topic=43096.msg483105#msg483105)
:whistling:
seriously,..I don't know how to do this...
but I think 250 drawing is not a big deal..
maybe by making it with a simple script file...?
-
Andrea,
I am amazed that you find my post from years ago with the same question of wich I had completely forgotten. Maybe I was sleepwalking that day... because I had also not responded to Irneb. That is not my style, I like to thank people that help me out. But in this case I guess I have not seen the reply at all and the post was forgotten....
Maybe a script, yes I may look into that.
Thanks,
Me!