     1	int MyApp::ExitInstance()
     2	{
     3	
     4	//
     5	// Your own code
     6	//
     7	
     8	        bool del = true;
     9	
    10	        try
    11	        {
    12	                TangoUtil *tg = TangoUtil::instance();
    13	        }
    14	        catch(Tango_DevFailed)
    15	        {
    16	                del = false;
    17	        }
    18	
    19	        if (del == true)
    20	                delete (TangoUtil::instance());
    21	
    22	        return CWinApp::ExitInstance();
    23	}
    24	 
