Parcel Center points

Parcel Center points

Anonymous
Not applicable
1,361 Views
8 Replies
Message 1 of 9

Parcel Center points

Anonymous
Not applicable

2014 (COM Preferred)

 

Are Parcel center points available in the API?

 

The origin of the Area Label would be ideal.

 

Thanks,

 

Kevin.

 

0 Likes
1,362 Views
8 Replies
Replies (8)
Message 2 of 9

Civil3DReminders_com
Mentor
Mentor

Yes, if you have the user select the parcel area label (or go through the objects in the drawing to find the parcel labels) there is an AnchorInfo property for the parcel area label. In it there is a location property which will have the information you requested.

 

http://docs.autodesk.com/CIV3D/2013/ENU/API_Reference_Guide/index.html

 

Well it looks like I can't link to the page, or I'm not smart enough to figure it out.

Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni
0 Likes
Message 3 of 9

Jeff_M
Consultant
Consultant

Only problem with that, Christopher, is the default Parcel Area Label (the one automatically added when a style is provided) is not selectable as a label (it is a Parcel) and the ParcelAreaLabels property of the Parcel only holds user added labels, not the default label. 

 

I have never found a way to get the default label's placement location. As for getting the centroid of the parcel, you could create a polygon from the Segments in the ParceLoop objects, from which you could calc the centroid.

 

Of course, I could be wrong and have not looked in the right places....Smiley Wink

Jeff_M, also a frequent Swamper
EESignature
0 Likes
Message 4 of 9

Civil3DReminders_com
Mentor
Mentor
It appears that the parcel has a grip point, you could use the grip point
property to get the location. It's not documented in the Civil 3D API, but
should be inherited from the base autocad object. But I haven't tried it
with the parcel object.
Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni
0 Likes
Message 5 of 9

Anonymous
Not applicable

Thx Jeff and Chris. It's great to get input from 2 of the best - and so quick. Just busy with a huge task, will try the grip recommendation later today.

 

0 Likes
Message 6 of 9

Anonymous
Not applicable

Adding to this - Sometime ago, I have created a 'wish list' for a .NET API for  the same. So, lets hope to see this direct API in the future release.

 

Thanks,

Partha

0 Likes
Message 7 of 9

Anonymous
Not applicable

Is it possible to use base.getgrippoints using interop (COM)?

I have not found it .. still searching.

Let me know if I can only do this within the managed API.

 

I moved back to Interop. There was a significant step I missed in making dll's using managed API. Some users, sometimes, encountered terrible net framework security warning messages when trying to issue custom commands. The solution was to edit the acad.config.exe. Thats the significant step I missed - to somehow make sure the warnings did not occur, and users not needing to edit the acad.config.exe.

 

Thx.

 

Kevin.

 

0 Likes
Message 8 of 9

Anonymous
Not applicable

oops *blush* getgrippoints was a custom defined method in an example 

.. still searching for entity grips ...

 

0 Likes
Message 9 of 9

Anonymous
Not applicable

coming back to the parcel label..

attached DWG has 1 parcel. It has a built in area selection label.

When I iterate thru model space objects using interop I get: aeccdbface (x2) and a aeccdblotline

no labels.

 

Using AECC_PARCEL filter selection:

when I check the parcel object for arealabels, the count is zero.

 

me thinks me must return to managed api ..

 

!

 

 

 

0 Likes