Author Topic: Values of VLAX-PUT & VLAX-GET ...  (Read 10885 times)

0 Members and 1 Guest are viewing this topic.

MP

  • Seagull
  • Posts: 17750
  • Have thousands of dwgs to process? Contact me.
Re: Values of VLAX-PUT & VLAX-GET ...
« Reply #15 on: May 01, 2010, 08:21:54 AM »
Yes, but not exclusively.

Try this (hope I type this out on my blackberry correctly, ain't ez) --

(vlax-get (setq object (vlax-ename->vla-object (car (entsel)))) 'EntityType)

Then this --

(vla-get-entitytype object)

*faceplant*
Engineering Technologist • CAD Automation Practitioner
Automation ▸ Design ▸ Drafting ▸ Document Control ▸ Client
cadanalyst@gmail.comhttp://cadanalyst.slack.comhttp://linkedin.com/in/cadanalyst

Lee Mac

  • Seagull
  • Posts: 12913
  • London, England
Re: Values of VLAX-PUT & VLAX-GET ...
« Reply #16 on: May 01, 2010, 01:05:50 PM »
Ooo didn't know about that one! In that case, I'm sure there are others. Thanks dude  :-)

alanjt

  • Needs a day job
  • Posts: 5352
  • Standby for witty remark...
Re: Values of VLAX-PUT & VLAX-GET ...
« Reply #17 on: May 01, 2010, 01:38:22 PM »
Yes, but not exclusively.

Try this (hope I type this out on my blackberry correctly, ain't ez) --

(vlax-get (setq object (vlax-ename->vla-object (car (entsel)))) 'EntityType)

Then this --

(vla-get-entitytype object)

*faceplant*

I know the returned integer pertains to the specific object, but what's the purpose of EntityType?
Civil 3D 2019 ~ Windohz 7 64bit
Dropbox

MP

  • Seagull
  • Posts: 17750
  • Have thousands of dwgs to process? Contact me.
Re: Values of VLAX-PUT & VLAX-GET ...
« Reply #18 on: May 03, 2010, 09:39:09 AM »
The succinct description from the property itself is "Returns the entity type of the object as an integer". Example, lines are 19, arcs are 4, circles 8 etc. Obviously they are members of an enumeration tho it appears not formally. That is, while I found the enumeration AcEntityName, with values confirming the preceding "lines are 19" etc. the return type for the EntityType property is not spec'd as AcEntityName but merely Long:

Property EntityType As Long
    read-only
    Member of AutoCAD.AcadLine
    Returns the entity type of the object as an integer.

Engineering Technologist • CAD Automation Practitioner
Automation ▸ Design ▸ Drafting ▸ Document Control ▸ Client
cadanalyst@gmail.comhttp://cadanalyst.slack.comhttp://linkedin.com/in/cadanalyst