Posts: 18
Registered: ‎09-13-2007
Message 1 of 2 (130 Views)

Object data to Aeccpoints

130 Views, 1 Replies
08-06-2012 04:53 PM

I want to be able to attach object data to a cogopoint, becuase we are having problems with the attribute data disappearing from the point. Here is what I have so far but getting a Autodesk.Gis.Map.MapException error thrown. 


oAeccApp = oAcadApp.GetInterfaceObject("AeccXUiLand.AeccApplication.9.0")
oAeccDoc = oAeccApp.ActiveDocument
oAeccDB = oAeccApp.ActiveDocument.Database

Dim oPoints As Autodesk.AECC.Interop.Land.AeccPoints
Dim oPoint As Autodesk.AECC.Interop.Land.AeccPoint
oPoints = oAeccDB.Points

Dim pointLocation As Point3d = Nothing

Dim location(0 To 2) As Double
location(0) = x
location(1) = y
location(2) = z
oPoint = oAeccDoc.Points.Add(CType(location, Object))
oPoint.RawDescription = myPoints(4)

oPoint.Number = pid
Dim id As ObjectId = PointEntity.FromAcadObject(oPoint)
Dim pt As PointEntity = acTrans.GetObject(id, Autodesk.AutoCAD.DatabaseServices.OpenMode.ForWrite, False)
Dim odtable As ObjectData.Table = tables(tablename)

' Create and initialize an record
Dim tblRcd As Record = Record.Create()

Dim val As MapValue = tblRcd(0) ' String type


For cnt = 1 To myPoints.GetUpperBound(0) - 3

val = tblRcd(cnt)
val.Assign(myPoints(cnt + 3))


val = tblRcd(12)

table.AddRecord(tblRcd, id)  ''Autodesk.Gis.Map.MapException is thrown here

Posts: 18
Registered: ‎09-13-2007
Message 2 of 2 (101 Views)

Re: Object data to Aeccpoints

08-08-2012 06:03 AM in reply to: tdunn3

I solved this by importing the points first and then running through the csv again to apply the object data.

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Are you interested in helping shape the Autodesk Community?
We’re looking at a few different ways to improve the “All Forums” landing page and need your feedback! If interested, please take a few minutes to fill out the following Usability Study. Thank you for your time!

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

Ask the Community