View Single Post

  #3 (permalink)  
Old 03-10-2006
Elbarto Elbarto is offline
Junior Member
Yellow Belt
 
Join Date: Mar 2006
Posts: 13
I use this code when my add-in is close:

Quote:

public void OnDisconnection(Extensibility.ext_DisconnectMode disconnectMode, ref System.Array custom)
{
if(app != null)
{
app.Quit( );
app = null;
}
}
"app" is the mappoint process

Quote:

public class Test
{
private MapPoint.Application app;

//constructor
public Test(object application)
{
app = application as MapPoint.Application;

}
maybe my method is incorrect ?

I want to know the general advice to make a correct add-in, fo a perfect exit of the application
Reply With Quote