Author Topic: need help on a macro (again)  (Read 1467 times)

0 Members and 1 Guest are viewing this topic.

ELOQUINTET

  • Guest
need help on a macro (again)
« on: July 28, 2006, 01:26:06 PM »
i am developing a macro which i want to do the following

1 save current osnaps
2 convert text to mtext
3 justify the text
4 move the text (during which i change the osnaps to endpoint only)
5 reset osnaps to previous

i have the macro working except for resetting the osnaps. it seems that after the move command completes the macro is terminating. what do i need to change or perhaps i have to use a different method?

^C^C^P(setq temp (getvar "osmode"))(princ);_TXT2MTXT;\\;JUSTIFYTEXT;L;;L;osmode;1;MOVE;L;;\\;;^P(setvar "osmode" temp)(setq temp nil)(princ);

Dommy2Hotty

  • Swamp Rat
  • Posts: 1128
Re: need help on a macro (again)
« Reply #1 on: July 28, 2006, 01:27:44 PM »
Try it without the second echo toggle:

^C^C^P(setq temp (getvar "osmode"))(princ);_TXT2MTXT;\\;JUSTIFYTEXT;L;;L;osmode;1;MOVE;L;;\\;;(setvar "osmode" temp)(setq temp nil)(princ);

ELOQUINTET

  • Guest
Re: need help on a macro (again)
« Reply #2 on: July 28, 2006, 04:36:22 PM »
i forgot here's the working macro

^C^C^P(setq temp (getvar "osmode"))(princ);_TXT2MTXT;\\;JUSTIFYTEXT;L;;L;osmode;1;MOVE;L;;\\(setvar "osmode" temp)(setq temp nil)(princ);

alot of our old drawings contain single line text and are all left justified (even when it is left of the detail) and it drives me crazy. i know some will say that is the correct way but i just like a clean text box around my detail. thanks dommy for your input.

craigr

  • Guest
Re: need help on a macro (again)
« Reply #3 on: July 31, 2006, 02:18:35 PM »
'Textjustfy' - Way cool!

I didn't know such a command existed! I've always pulled up the properties box and changed it there.

Thanks for posting this. I am making the macros now!

craigr

Dommy2Hotty

  • Swamp Rat
  • Posts: 1128
Re: need help on a macro (again)
« Reply #4 on: July 31, 2006, 05:14:40 PM »
'Textjustfy' - Way cool!

...

Thanks for posting this. I am making the macros now!

craigr

I guess I should interject before you get too far into your macro making proccess:
Command is JUSTIFYTEXT

craigr

  • Guest
Re: need help on a macro (again)
« Reply #5 on: August 01, 2006, 08:47:44 AM »
Yes, I see I did type that Backwards.

My macros work great, so at least I got it right where it really counts.

thanks again,
craigr

ELOQUINTET

  • Guest
Re: need help on a macro (again)
« Reply #6 on: August 01, 2006, 08:52:40 AM »
yeah this macro will be sweet for our old detail that have dtext, glad you like craig