Community
Civil 3D Customization
Welcome to Autodesk’s AutoCAD Civil 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Civil 3D Customization topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Fatal Error: Create COGO Point (2014)

1 REPLY 1
Reply
Message 1 of 2
krondys
513 Views, 1 Reply

Fatal Error: Create COGO Point (2014)

I am absolutely perplexed by a problem I am having...  I have a plugin that creates cogo points, and for some users it seems to crash every time, but for others it works just fine (as for myself, I have zero problems with it).  The subroutine is simple:

 

Using civLock As DocumentLock = acadDoc.LockDocument
     Using trans As Transaction = db.TransactionManager.StartTransaction()
          Try
               Dim Location As New Point3d(PointX, PointY, PointZ)
               Dim CogoPoints As CogoPointCollection = civilDoc.CogoPoints
               Dim PointID As ObjectId = CogoPoints.Add(Location)
               Dim NewPoint As CogoPoint = PointID.GetObject(OpenMode.ForWrite)
               NewPoint.RawDescription = PointD
               NewPoint.ApplyDescriptionKeys()
               trans.Commit()
          Catch ex As ArgumentException
          End Try
     End Using
End Using

 

The fatal error occurs when the point is added, prior to the attempt to assign a raw description.  What is boggling me is that, like I said, it works flawlessly for me (and others) but not at all for some users.

1 REPLY 1
Message 2 of 2
Partha.Sarkar
in reply to: krondys

Hi,

 

Is this specific to a particular DWG file for those users where it crashes ?

 

What's the error message it shows ?

 

Thanks,



Partha Sarkar
Developer Technical Services
Autodesk Developer Network

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


 

Autodesk Design & Make Report