.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

auto lisp comman .net

4 REPLIES 4
Reply
Message 1 of 5
cihanbaki2147
246 Views, 4 Replies

auto lisp comman .net

how  to  atulisp  command  run  autocad.net  ?

4 REPLIES 4
Message 2 of 5
_gile
in reply to: cihanbaki2147

Hi,

 

You can use the Document.SendStringtoExecute() method but you have to keep in mind it runs asynchrously.

Another way (which works synchronously is using Application.Invoke(). You'll find some code snippets in this thread.



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Message 3 of 5

Hi @cihanbaki2147,

 

Just by completing the @_gile answer:
Document.Editor.Command() by Autodesk.AutoCAD.EditorInput namespace is another approach to executing commands by In-Process plugins and AcadApplication.ActiveDocument.SendCommand ("('CMD_NAME') command) to send lisps by C # encoding. NET.

 

 

Att,

Antonio Leonardo

exam-483-programming-in-c.png

Message 4 of 5
_gile
in reply to: antonio.leonardo


@antonio.leonardo wrote:

Hi @cihanbaki2147,

 

Just by completing the @_gile answer:
Document.Editor.Command() by Autodesk.AutoCAD.EditorInput namespace is another approach to executing commands by In-Process plugins


 

As far as I know, you cannot call an AutoLISP defined command (or any other kind of LISP function) with Editor.Command() which only accepts native commands and .NET or ObjectARX custom commands.



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Message 5 of 5
antonio.leonardo
in reply to: _gile

Yes @_gile, you're wrigth. Thanks.

 

@cihanbaki2147, sorry for answer. Please, considering only an out-of-process approach as  AcadApplication.ActiveDocument.SendCommand (<write your AutoLisp here...>) as a way to Out-of-process plugin.

 

Att,

Antonio Leonardo

exam-483-programming-in-c.png

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

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost