首先在lisp中写好你的代码,这里就搞个最简单的:
(defun c:hello()
(alert "\nhello world!")
)

然后在你的C#代码中加入代码:
ResultBuffer args = new ResultBuffer(new TypedValue((int)LispDataType.Text, "c:hello"));
ResultBuffer result = Application.Invoke(args);
Editor ed = Application.DocumentManager.MdiActiveDocument.Editor;
ed.WriteMessage(result.ToString());

更多CAD二开问题,请加我的QQ群:193522571

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案