TheSwamp

Code Red => AutoLISP (Vanilla / Visual) => Topic started by: jbuzbee on March 25, 2008, 04:34:57 PM

Title: Anotative Blocks
Post by: jbuzbee on March 25, 2008, 04:34:57 PM
AutoCAD 2008

Does anyone know where this property is kept? I looked at everything exposed in ActiveX and also DXF for a BLOCK_RECORD.  I sure would like to find a programatic way to change old tag blocks to take advantage of this new feature . . ..

Thanks for any insight
Title: Re: Anotative Blocks
Post by: Guest on March 25, 2008, 04:39:44 PM
Is this what you're looking for?

Quote
ANNOTATIVEDWG
Specifies whether or not the drawing will behave as an annotative block when inserted into another drawing
Title: Re: Anotative Blocks
Post by: jbuzbee on March 25, 2008, 04:40:21 PM
Doh! never mind.  It's in the block editor . . .

. . . must go home now - it's been a hard week :x
Title: Re: Anotative Blocks
Post by: Guest on March 25, 2008, 04:40:58 PM
Doh! never mind.  It's in the block editor . . .

. . . must go home now - it's been a hard week :x

Dude!!  It's only Tuesday!!   :roll:   :wink:
Title: Re: Anotative Blocks
Post by: Marco Jacinto on March 25, 2008, 07:15:04 PM
JB, where it is located, haven't found a way to get it via VisualLisp.

I already now where it is in the Block editor.

Saludos
Marco Jacinto
Title: Re: Anotative Blocks
Post by: T.Willey on March 25, 2008, 07:35:21 PM
I don't see a way with just ActiveX, but you can get almost the whole way there with ActiveX.

Get the extension dictionary of the object.
Then you need to get a dictionary from the extension dictionary called: "AcDbContextDataManager"
Then from there you get a dictionary called: "ACDB_ANNOTATIONSCALES"
And that holds the annotation scales, but I don't see how with ActiveX, but you can see it with Lisp and Dxf codes.

ActiveX dump
Quote
; IAcadObject: The standard interface for a basic AutoCAD object
; Property values:
;   Application (RO) = #<VLA-OBJECT IAcadApplication 00d73d3c>
;   Document (RO) = #<VLA-OBJECT IAcadDocument 01e06e20>
;   Handle (RO) = "157"
;   HasExtensionDictionary (RO) = 0
;   ObjectID (RO) = 2130658360
;   ObjectName (RO) = "AcDbBlkRefObjectContextData"
;   OwnerID (RO) = 2130658352
; Methods supported:
;   Delete ()
;   GetExtensionDictionary ()
;   GetXData (3)
;   SetXData (2)
T

Lisp dump
Quote
(-1 . <Entity name: 7eff4438>)
(0 . "ACDB_BLKREFOBJECTCONTEXTDATA_CLASS")
(5 . "157")
(102 . "{ACAD_REACTORS")
(330 . <Entity name: 7eff4430>)
(102 . "}")
(330 . <Entity name: 7eff4430>)
(100 . "AcDbObjectContextData")
(70 . 3)
(290 . 1)
(100 . "AcDbAnnotScaleObjectContextData")
(340 . <Entity name: 7eff4038>)
(50 . 0.0)
(10 38.5594 27.4078 0.0)
(41 . 1.0)
(42 . 1.0)
(43 . 1.0)

Where code 340 tells you what the scale is
Quote
(-1 . <Entity name: 7eff4038>)
(0 . "SCALE")
(5 . "B7")
(102 . "{ACAD_REACTORS")
(330 . <Entity name: 7eff4030>)
(102 . "}")
(330 . <Entity name: 7eff4030>)
(100 . "AcDbScale")
(70 . 0)
(300 . "1:1")
(140 . 1.0)
(141 . 1.0)
(290 . 1)

Hope that helps.
Title: Re: Anotative Blocks
Post by: jbuzbee on March 26, 2008, 08:11:04 AM
AutoCAD making it more and more difficult for customization. :x

Why the heck isn't this just a property? It's either on or off!!

Oh well.

Thanks everyone for your input - Matt, I know.

If I have time I'll delve into this more deepley and post my findings - trying to get the office up and running on 2008 . . ..