.NET

.NET

Reply
Distinguished Contributor
JanetDavidson
Posts: 141
Registered: ‎08-23-2011
Message 1 of 6 (260 Views)
Accepted Solution

How edit an Associatvie Array entity in 2012 Programmatically?

260 Views, 5 Replies
03-22-2012 09:37 AM

My plan is to edit an Associative array entity  Programmatically and I don't know where to start.

 

Why can't I cast a DBobject to AssocArray ?

something like this?

Dim myarray As AssocArray = TryCast(mydbobj, AssocArray)

 

Why TypeOf  dbobject  is BlockReference ?

 

Can I get some right direction Here Please? I stuck right at begining.

Thanks Janet.

 

 

 

 

I haven't played with them yet, but if memory serves, I think Stephen Preston did a DevCast on the subject.

 

A quick search gave me this Through the Interface Post:

http://through-the-interface.typepad.com/through_the_interface/2011/11/creating-a-simple-associative-autocad-array-along-a-path-using-net.html

 

Which also points to this TTIF post:

http://through-the-interface.typepad.com/through_the_interface/2011/03/new-apis-in-autocad-2012.html

 

The second post has links to download the DevTV session.

*Expert Elite*
chiefbraincloud
Posts: 753
Registered: ‎02-13-2008
Message 2 of 6 (247 Views)

Re: How edit an Associatvie Array entity in 2012 Programmatically?

03-22-2012 03:17 PM in reply to: JanetDavidson

I haven't played with them yet, but if memory serves, I think Stephen Preston did a DevCast on the subject.

 

A quick search gave me this Through the Interface Post:

http://through-the-interface.typepad.com/through_the_interface/2011/11/creating-a-simple-associative...

 

Which also points to this TTIF post:

http://through-the-interface.typepad.com/through_the_interface/2011/03/new-apis-in-autocad-2012.html

 

The second post has links to download the DevTV session.

Dave O.                                                                  Sig-Logos32.png
Distinguished Contributor
JanetDavidson
Posts: 141
Registered: ‎08-23-2011
Message 3 of 6 (245 Views)

Re: How edit an Associatvie Array entity in 2012 Programmatically?

03-22-2012 03:39 PM in reply to: chiefbraincloud

Hello chief, 

Thanks for reply and helping me again .

 

I saw that and I was able to create them using that link. Now question is how could I edit them after they added to database. Because after I get DBobject  I can't even cast them to get the proper  class.

 

Distinguished Contributor
JanetDavidson
Posts: 141
Registered: ‎08-23-2011
Message 4 of 6 (240 Views)

Re: How edit an Associatvie Array entity in 2012 Programmatically?

03-22-2012 04:24 PM in reply to: chiefbraincloud

Hello Chief . I knew you never make mistake. That is why I double check the second Link which was TTIF post. and I found what I want. Thanks again. Sorry I rushed to answer at first place.

Regards,

Janet.

 

*Expert Elite*
chiefbraincloud
Posts: 753
Registered: ‎02-13-2008
Message 5 of 6 (238 Views)

Re: How edit an Associatvie Array entity in 2012 Programmatically?

03-22-2012 04:33 PM in reply to: JanetDavidson

Oh, believe me, I make mistakes.  Glad this wasn't one of those times. :smileywink:

Dave O.                                                                  Sig-Logos32.png
Valued Mentor
jeff
Posts: 338
Registered: ‎05-12-2009
Message 6 of 6 (235 Views)

Re: How edit an Associatvie Array entity in 2012 Programmatically?

03-22-2012 05:35 PM in reply to: chiefbraincloud

Here is one approach but might be a better way of doing it

 

http://www.theswamp.org/index.php?topic=37921.msg464320#msg464320

 

but

AssocArray.GetParameters

modify parameters

Commit 

You can also find your answers @ TheSwamp
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.