Hi Peter
My VB is about worthless, about all I can do is use reflector. you will need to add the LispDataTypes back in.
I hope this helps you
Public Class Commands
' Methods
<DllImport("acad.exe", CallingConvention:=CallingConvention.Cdecl)> _
Private Shared Function acedInvoke(ByVal rbIn As IntPtr, <Out> ByRef rbOut As IntPtr) As Integer
End Function
Public Shared Function Invoke(ByVal rbIn As ResultBuffer) As ResultBuffer
Dim pRb As IntPtr = IntPtr.Zero
Commands.acedInvoke(rbIn.UnmanagedObject, pRb)
Return TryCast(DisposableWrapper.Create(GetType(ResultBuffer), pRb, True),ResultBuffer)
End Function
<CommandMethod("doit")> _
Public Shared Sub MyCommand()
Dim rbOut As New ResultBuffer
rbOut.Add(New TypedValue(5005, "thisisatest"))
rbOut.Add(New TypedValue(5016))
rbOut.Add(New TypedValue(5010, 1))
rbOut.Add(New TypedValue(5010, 2))
rbOut.Add(New TypedValue(5010, 3))
rbOut.Add(New TypedValue(5010, 4))
rbOut.Add(New TypedValue(5017))
New List(Of TypedValue)(Commands.Invoke(rbOut).AsArray).ForEach(Function (ByVal X As TypedValue)
Application.DocumentManager.MdiActiveDocument.Editor.WriteMessage(X.Value.ToString)
End Function)
End Sub
End Class