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

Unable to find an entry point named 'acedInvoke' in DLL 'acad.exe'

3 REPLIES 3
Reply
Message 1 of 4
JeffatSJE
1234 Views, 3 Replies

Unable to find an entry point named 'acedInvoke' in DLL 'acad.exe'

.net 4 change caused the following code to hang (sample from help file) 

 

any documentation on how do fix this?

 

 

        [System.Security.SuppressUnmanagedCodeSecurity]
        [DllImport("acad.exe", CallingConvention = CallingConvention.Cdecl)]
        extern static private int acedInvoke(IntPtr args, out IntPtr result);

        // Helper for acedInvoke()
        public static ResultBuffer InvokeLisp(ResultBuffer args, ref int stat)
        {
           IntPtr rb = IntPtr.Zero;
           stat = acedInvoke(args.UnmanagedObject, out rb);
           if (stat == (int)PromptStatus.OK && rb != IntPtr.Zero)
               return (ResultBuffer)
              DisposableWrapper.Create(typeof(ResultBuffer), rb, true);
           return null;
        }

 

Thanks

J

3 REPLIES 3
Message 2 of 4
_gile
in reply to: JeffatSJE

Hi,

 

AFAIK, this is not a related to .NET Framework 4.0 but to the AutoCAD 2013 .NET API.

Replace acad.exe with accore.dll, or, better, use the managed Application.Invoke() method which wraps the ObjectARX acedInvoke method (since A2011).



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Message 3 of 4
JeffatSJE
in reply to: JeffatSJE

Changing acad.exe to accore.dll worked great!

 

Thank You! Smiley Happy

 

Most of my routines use this code to access lisp api call data. If you know of any examples using Application.Invoke() that does the same I would learn something new.

 

Thanks Again,

Jeff

 

Message 4 of 4
_gile
in reply to: JeffatSJE

As P/Invoking acedInvoke, the Application.Invoke() method requires a single argument as ResultBuffer and returns the LISP return value as a ResultBuffer.



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

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