Lee Mac Posted June 1, 2009 Posted June 1, 2009 I realise this can be achieved without the use of Visual LISP using entmake, however, I am intrigued as to the Visual LISP alternative, if indeed, there is one. I have read the help article on "vla-add", but this seems to only require a basepoint and Block name String. So how does one add the necessary objects to the block definition? Thanks, Lee Quote
fixo Posted June 1, 2009 Posted June 1, 2009 Then you need to add to this block definitions all of the entities you want The same way as for vla-add-modelspace but in this case you need to write: vla-addline etc etc vla-addattribute etc etc Sorry for my bad explanation, hope you're understand ~'J'~ Quote
wizman Posted June 1, 2009 Posted June 1, 2009 just like fixo is saying, think of the block as another space: (setq myblockspace (vla-add (vla-get-Blocks (vla-get-ActiveDocument (vlax-get-acad-object))) (vlax-3d-point '(0 0 0)) "testblock" )) (vla-addline myblockspace (vlax-3d-point '(0 0 0)) (vlax-3d-point '(0 1 0))) Quote
Lee Mac Posted June 1, 2009 Author Posted June 1, 2009 Then you need to add to this block definitions allof the entities you want The same way as for vla-add-modelspace but in this case you need to write: vla-addline etc etc vla-addattribute etc etc Sorry for my bad explanation, hope you're understand ~'J'~ Yes, I understand perfectly, thanks as always Fixo Quote
Lee Mac Posted June 1, 2009 Author Posted June 1, 2009 Thanks Wizman for the example - much appreciated Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.