• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    AutoCAD Civil 3D Customization

    Reply
    Valued Contributor
    Posts: 62
    Registered: ‎12-10-2004

    Find insertion point for a surface label

    112 Views, 1 Replies
    08-01-2012 10:12 AM

    If I use this code it will give me the insertion point for a block

    (setq ent (car (entsel "\nSelect Main Object: ")))

    (setq InsPt (assoc 10 (entget Ent)))

     

    Now if I try to use this for a surface label and try to get the insertion point

    (setq ent (car (entsel "\nSelect Main Object: ")))

    (setq oEnt (vlax-Ename->Vla-Object ent))
    (vlax-dump-object oEnt)

     

    I dont see anything that will help me get the insertion point.  Is there some other sneaky way or utility function that can help me do this?

     

    Help? :-)

     

    thanks a bunch!

    dg

    Please use plain text.
    Active Contributor
    Posts: 30
    Registered: ‎02-17-2010

    Re: Find insertion point for a surface label

    08-01-2012 11:50 AM in reply to: DavidGarrigues5269

    Not sure AutoLisp "sees" any property of a surface label like insertion point. It is possible though to get a surface label "location" property using .net api (Civil3D 2013 in any case). Spot elevation labels have only one "location" property, but it might be different with other labels (for exapmle surface slope label can have 2 such properties - "location" and "location2"). Check the api reference here:

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

     

    In case of spot elevation label you might be intrested in Autodesk.Civil.DatabaseServices Namespace -> SurfaceElevationLabel Class -> SurfaceElevationLabel Properties -> Location 

     

     

     

     

    Please use plain text.