Jump to content

system variable allow exploding


MartinSomerville

Recommended Posts

hey all...just wanting to know how to change the flag in the block dialog box "allow exploding". has it a sys variable? I know how to make all blocks in the drawing explodable. I just want to know how to change that flag for all future made blocks.

Unless I create a dummy block and check that "allow exploding" box and save I don't know how to change all future made blocks so they are explodable. (i don't create blocks with the dialog box all the time)

 

thanks

martin

Link to comment
Share on other sites

The Allow exploding check box remains the same as the last block you create.

 

If you make a block and tick the "allow Exploding" and onpen a new drawing and make another block, the "allow Exploding" box will still be ticked.

If you make another block and untick the "allow Exploding" box, the next block you make will be unticked as well.

 

Hope that made sense

Link to comment
Share on other sites

To determine the current value use:

;; allow-explode-p
;; returns 1 or 0 (Yes or No)
;;
(defun allow-explode-p ()
   (vl-registry-read
       (strcat
           "HKEY_CURRENT_USER\\"
           (vlax-product-key)
           "\\Profiles\\"
           (vla-get-activeprofile
               (vla-get-profiles
                   (vla-get-preferences (vlax-get-acad-object))
               )
           )
           "\\Dialogs\\block_definition_dialog"
       )
       "Explode"
   )
)
;;
;;
;; wiz_04DEC09

To set it to 'allow exploding' use:

;; allow-explode
;; 
;;
(defun allow-explode ()
   (vl-registry-write
       (strcat
           "HKEY_CURRENT_USER\\"
           (vlax-product-key)
           "\\Profiles\\"
           (vla-get-activeprofile
               (vla-get-profiles
                   (vla-get-preferences (vlax-get-acad-object))
               )
           )
           "\\Dialogs\\block_definition_dialog"
       )
       "Explode"
       1
   )
)
;;
(allow-explode)
;;
;;
;; wiz_04DEC09

Link to comment
Share on other sites

thanks lads.. appreciate any response..this site is very friendly and helpful...

 

steve..yeah i got that :) i use a make all blocks explodable routine but I wanted it to set the "future" blocks flag to allow exploding aswell!!...so I can use a little command line quick block routine I have... without having to run dialog box (i know, I'm lazy :) )

 

thanks wizman - that looks quite funky...i havevn't done anything like that before...i'll check it at work on monday!! no wonder I couldn't figure it out..

 

thanks again all

 

martin

Link to comment
Share on other sites

..actually steve..i read your post again..so maybe the template our office uses has don't allow blocks checked!!! I'll check with the customise fellow here to check....maybe he should run dialog, set to allow exploding and then export template again :)

Link to comment
Share on other sites

thanks lads.. appreciate any response..this site is very friendly and helpful...

 

martin

 

 

Glad to share MartinSomerville, Cheers Lee.....:)

Link to comment
Share on other sites

..actually steve..i read your post again..so maybe the template our office uses has don't allow blocks checked!!! I'll check with the customise fellow here to check....maybe he should run dialog, set to allow exploding and then export template again :)

 

Could be an idea mate. change the setup of the .dwt

Link to comment
Share on other sites

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...