@mhupp
Thanks for the answer!!
It will take me some time to learn this code,
but there is one fundemental issue that i'm trying to figure out for some time:
this type of code - (setq blk (cdr (assoc 2 (entget e))))
"e" is set to a block entity,and that block entity do have a list of arguments,that is clear.
cdr means "get the second item on that arguments list (or just any list..)".
in the dxf-reference_enu, both in the BLOCKS Section (Chapter 5 BLOCKS Section) and the insert section (Chapter 6 ENTITIES Section) the block name is indeed assoc code 2 (I've attached a screenshot from the dxf manual),so that is also clear to me why the use of assoc 2.
so why the use of cdr?
1. what is the logic Behind this, and why it is wrong to write "(setq blk (assoc 2 (entget e)))?
2. why do we need the entget when e is already set to a block object,which means that it an entity from the beginning?
thanks for patience...
Ari.