Jump to content

Recommended Posts

Posted

Hey,

I have an updated version of a code LeeMac gave me. I am wondering how I would change a property of the Text itself tho. I want to change the 'width factor' to 0.8 and am unsure how to do it. Would I set a new cons in the LM:Text to set the width factor...? Any help is appreciated.

 

Kenter

Lee TEF.LSP

Posted

It seems to me... Yes. Try Inserting the following into the LM:Text portion:

 

 
(cons 41 0.

Posted

How do you know that? It worked. Prefectly infact. I just don't understand how you knew that. Seems so random to me. lol

Posted

I would have to agree with you. I find dxf codes to be confusing as well. How I figured them out is mostly by experimenting with changing the values.

 

 
(DEFUN C:GETDATA ()
 (SETQ SS (SSGET ":s"))
 (SETQ SSN (SSNAME SS 0))
 (SETQ EN (ENTGET SSN))
 (PRINC)
 (TEXTPAGE)
 (PRINC en)
 (princ)
)

 

The above code retrieves the entity data. I retrieved the entity data and then I change the value of the width factor in the properties and then I retrieved the entity data again to see what changed. In this case association 41 had changed to the value in the width factor... so ok... dxf code 41 changes the width factor. Or one could just do thier research to find what dxf codes represent but what fun would that be! :D

 

regards,

 

hippe013

Posted

That is sweet. I will deffinetly write that code down. Thank you so much.

 

Kenter

Posted

No problem! :) Though personally I would use copy and paste... :thumbsup: J/K

 

hippe013

Posted
How do you know that? It worked. Prefectly infact. I just don't understand how you knew that. Seems so random to me. lol

 

 

See here Kenter:

http://images.autodesk.com/adsk/files/acad_dxf1.pdf

Posted

Nice! :D This will certainly come in handy! Thanks!

Posted

Thank you very much Lee. That will deffinetly come in handy. :)

Posted

Here's a nice way to look at entity data (VLA and DXF)...

 

(defun c:Info (/ opt obj)
 ;; VLA & DXF Info of selected Primary or Nested object
 ;; Alan J. Thompson
 (initget 0 "Nested Primary")
 (setq opt (cond ((getkword "\nSpecify selection mode [Nested/Primary] <Primary>: "))
                 ("Primary")
           )
 )
 (if (setq obj (car ((if (eq opt "Primary")
                       entsel
                       nentsel
                     )
                      (strcat "\nSelect " opt " object for VLA & DXF info: ")
                    )
               )
     )
   (progn
     (textscr)
     (princ "\nVLA Info:\n\n")
     (vlax-dump-object (vlax-ename->vla-object obj) T)
     (princ "\nDXF Info:\n")
     (mapcar 'print (entget obj))
   )
 )
 (princ)
)

Posted

Oh yeah, thanks for the newer DXF link, Lee.

Posted
Oh yeah, thanks for the newer DXF link, Lee.

 

No worries mate :)

 

FYI, I use MP's EList.lsp to view entget data, I think there is also his Info.lsp - they all do pretty much the same thing :)

Posted
No worries mate :)

 

FYI, I use MP's EList.lsp to view entget data, I think there is also his Info.lsp - they all do pretty much the same thing :)

Yeah, a lot of those, but I wanted one that would give VLA and DXF for a primary and nested object.

Posted
Yeah, a lot of those, but I wanted one that would give VLA and DXF for a primary and nested object.

 

Yeah, I think Info.lsp does that - but I use EList as I don't always want VLA all the time - but in any case it's more rewarding to roll your own :)

Posted
Yeah, I think Info.lsp does that - but I use EList as I don't always want VLA all the time - but in any case it's more rewarding to roll your own :)
Nah, his was Info an NInfo. I wanted to wrap everything into one.
Posted
Nah, his was Info an NInfo. I wanted to wrap everything into one.

 

Oh right - nice one.

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