I am trying to call AutoCAD Electrical API commands (LISP based) in .NET and in the documentation it states that it returns the entity name.
In the .NET developers guide it says under the section "Working with ObjectID's" that the 3 ways to access an object are:
What is this entity name, is there a .NET equivalent, and how can I use it to access the database?
Solved! Go to Solution.
Solved by caddzone. Go to Solution.
The managed equivalent of an entity name is an ObjectId.
If a LISP function is called from .NET, and it returns an entity
name, the returned ResultBuffer will contain an ObjectId.
Conversely, if you call a LISP function from .NET that takes
an entity name as an argument, the ResultBuffer argument
must contain an ObjectId.
Thanks! That makes sense, it would be nice if everyone referred to it as an ObjectId rather than in some cases calling it a name (which could be confused with block name)
@tonofsteel wrote:Thanks! That makes sense, it would be nice if everyone referred to it as an ObjectId rather than in some cases calling it a name (which could be confused with block name)
No, because "it" is not "it" it is "them" - and they are not the
same thing. They are transalated from one (entity name) to
the other (ObjectId) depending on which direction they're
going.
From above:
"Conversely, if you call a LISP function from .NET that takes
an entity name as an argument, the ResultBuffer argument
must contain an ObjectId."
From what I see after messing around with this in code is that the ObjectID is just that, and the "entity name" is a typed value that has the Value of ObjectID and TypeCode of (int)LispDataType.ObjectID which happens to be 5006, is it this typed value that is being called the "entity name"? I am not very familiar with Lisp, but I thought that since you send it typed values and it returns typed values, that is how it represents different data, or does it convert a typed value into a totally different datatype that is the so called "entity name"?