Jump to content

Recommended Posts

Posted

I have generated the following Macro in a drop down menu for quick insertion of some of my company's standard blocks. I want to know how to add the function explode to the command so as soon as I have placed the block using the macro it exploded on placement or selection of the macro.

 

^C^C-insert;F:/Blocks/CAN.dwg

  • Replies 21
  • Created
  • Last Reply

Top Posters In This Topic

  • garygoude

    8

  • Tyke

    5

  • Tuns

    5

  • rkmcswain

    3

Top Posters In This Topic

Posted

Precede the block name with an asterick and it will be exploded upon insertion.

 

Why would you want to do that?

Posted

^C^C-insert;F:/Blocks/CAN.dwg;\explode;last;;

I don't know if that will work. I didn't even try it.

Posted
^C^C-insert;F:/Blocks/CAN.dwg;\explode;last;;

I don't know if that will work. I didn't even try it.

 

See Remark's answer. The * will do it.

[Ref: -INSERT command]

Posted

Thanks, I have goen with the * method and it has worked perfectly. In reply to ReMark, I need to explode to block because it holds visibility parameters. Without the * I found I needed to explode the block once to release the visibility drop down 'grip'.

 

Thanks all for the fast responses!

Posted
Precede the block name with an asterick and it will be exploded upon insertion.

 

Why would you want to do that?

 

We have quite a lot of standard text (very short just a couple of words) and save each of them as a block and when you explode the block on insertion you have your text entity. Layer, colour, rotation, etc can all be set in the macro. Much neater is to do it from a custom palette where you can set layer, colour, etc and even explode it on insertion and dynamically set the rotation of the text, which is great when your text is not necessarily horizontal or vertical but can vary.

Posted
Oh, I never knew that. Thanks. :)

 

A before the command -INSERT will cause the insertion to loop until Esc is pressed.

Posted
A before the command -INSERT will cause the insertion to loop until Esc is presses.

I know that, but that isn't what I meant. I didn't know that a * before the block name would explode the block when inserted.

Posted

Just a quick follow up question guys....my new macro that albeit works fine (^C^C-insert;*F:/Blocks/CAN.dwg) obviously asks me to pick an insertion point with my cursor, this is fine, but then it asks to specify the scale and then the rotation angle. Both of which can be bypassed with two right clicks or two space bar presses, but is there any extra code that can be put on the end of the macro to specify I want the inserted block not to be scaled and a zero rotation angle? Just trying to streamline the process even faster.

Posted

Thanks for these guys both worked fine but I had to change this...try ^C^C-insert;*F:/Blocks/CAN.dwg;\1;1;0 to this...try ^C^C-insert;*F:/Blocks/CAN.dwg;\1;0;0 .....sure it was just a typo though! :)

 

I am guessing that in the case of ^C^C-insert;*F:/Blocks/CAN.dwg;\;; the "\;;" is the command for ENTER ENTER?

 

Is there anywhere good I can learn more about macro commands, a lot of what we do to relies on blocks and standard parts in our drawings and some more knowledge would be useful to streamline the drawings we produce.

 

Thanks

Posted

I am guessing that in the case of ^C^C-insert;*F:/Blocks/CAN.dwg;\;; the "\;;" is the command for ENTER ENTER?

 

Is there anywhere good I can learn more about macro commands, a lot of what we do to relies on blocks and standard parts in our drawings and some more knowledge would be useful to streamline the drawings we produce.

 

Thanks

Yes, ";" in a macro = "Enter".

This is a good place to start if you want to learn the basics. After you learn the basics, it would be smart to learn about diesel expressions.

Posted

Thanks for that Tuns, bedtime reading for tonight!

 

Thanks again everyone!

Posted

Thanks Tyke, only scan read your links just now but all looks like really useful stuff. Cheers :thumbsup:

Posted
Thanks Tyke, only scan read your links just now but all looks like really useful stuff. Cheers :thumbsup:

 

You're welcome mate, any time :beer:

Posted
Oh, I never knew that. Thanks. :)

 

No problem, there are a lot of good old command line tricks out there 8)

Posted

Hi guys, I am still having some problems with these macros. I have this macro:-

 

^C^C-insert;*F:/Blocks/CAN.dwg;\1;0;0

 

Which as I have understood so far, allows me to insert and explode a block from a given file location, then pause for defining the insertion point, then automatically sets scale at 1 and rotation at 0.

 

The trouble I have is with the insertion point. The command pauses for me to click an insertion point, but the block jumps over to the lower left rather than the insertion point I have selected. I have the source file defined correctly about 0,0,0 and I cannot make head nor tail or the coordinates the blocks are jumping to.

 

Any ideas?

 

I have attached the source file if that helps...

CAN.dwg

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...