Message 1 of 2
Not applicable
09-19-2014
10:41 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I'm hoping to get some assistance with resolving an error in calling an Autolisp program with the Invoke method. The following code returns an eInvalidInput error.
Public Sub CallLisp(strFName As String)
Try
Dim resbuf As New AccDb.ResultBuffer((New AccDb.TypedValue(CInt(LispDataType.Text), strFName)))
Autodesk.AutoCAD.ApplicationServices.Core.Application.Invoke(resbuf)
Catch ex As Exception
MsgBox("CallLisp: " & ex.Message)
Debug.Print(ex.Message)
End Try
End SubThe Autolisp program is loaded in the drawing and I can call it from the command line without issue. I've made sure to use vl-acad-defun to register the Autolisp command but can't seem to get around this error. I'm relatively new to trying to use the ResultBuffer so don't know if that is where my error is.
Trying to upgrade from AutoCAD 2011 to 2014 and need the Autolisp to be synchronous with the .Net code. Have looked at a number of forum posts including:
http://forums.autodesk.com/t5/net/resultbuffer-and-application-invoke/m-p/5212711/highlight/true#M41...
Any help will be appreciated.
Bernie
Solved! Go to Solution.