Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Adding variable to existing lisp...

3 REPLIES 3
Reply
Message 1 of 4
sean.keohane
262 Views, 3 Replies

Adding variable to existing lisp...

Hi,

I have attached 2 lisp files. datblkx5 makes a block of selection, inserts the block with a 5x distortion, explodes it, and corrects the text for width factor and text height. This one works fine.

I wanted to add the feature of scaling my selection with a user input value. This is the lisp datblkxxx. This one doesn't work. (that is it doesn't correct the text for width factor). I can't figure it out.

I'd appreciate it if someone could take a look and set me straight.

Regards

Sean

3 REPLIES 3
Message 2 of 4
anim8er3
in reply to: sean.keohane

Without even looking at the code, I can tell you that the STYLE settings for the text could defeat your efforts. Do you want the text to retain it's original size? Or do you want it to scale up/down?

Message 3 of 4
sean.keohane
in reply to: anim8er3

Hi,

The Text is sized with the mt1 and mt2 variable. This works OK when the scale factor is set ( to 5 in the datblkx5 lisp).

It all goes wrong when I try to introduce a user input variable for this factor. (for any scale, as in datblkxxx lisp).

I'm not sure I understand your observation though, can you explain it further?

thanks

Sean

Message 4 of 4
anim8er3
in reply to: sean.keohane

You are searching for text with a specific width factor, perhaps your text is not exactly that width factor once exploded out of the block. Therefore, it would not be added to the selection set you are changing, so no change occurs. I would check the math or perhaps find another way to add the text to the selection set. Use a different selection set search method.

 

My previous concert was that a text height and width factor are set for a text style. Under some circumstances, your text may revert to those settings despite having been set in the text object as something different. Probably not the issue here.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost