Trying to write an event handler for a lisp routine ending. This is what I've come up with Based on other event handlers examples;
[CommandMethod("Test1")]
static
public void Test1() // This method can have any name
{
.....
Document doc = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument;
doc.LispEnded +=
new ???????(OnLispEnded);
....
}
private void OnLispEnded(object sender, CommandEventArgs e)
{
Editor ed = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument.Editor;
Document doc = sender as Document;
ed.WriteMessage("...LispEnded = " + e.ToString());
}
Is this heading in the right direction? What would ??????? be?
Thanks, Andrew
something like this:
public void Test1()
{
Document doc = Application.DocumentManager.MdiActiveDocument;
doc.LispEnded += new System.EventHandler(OnLispEnded);
}
private void OnLispEnded(object sender, System.EventArgs e)
{
}