コード例 #1
0
 /// <summary>
 /// We recommend that you use our project templates (FrwSimpleWinCRUDTemplate) to build your own application.
 /// But if you prefer not to use our templates, then you need to call the following minimum sequence of methods
 /// when completing the application
 /// </summary>
 /// <param name="sender">Main form that closing application (Close button pressed) </param>
 static public void ShutdownExample(object sender)
 {
     //on form closing event
     AppManager.Instance.SaveAndClose((Form)sender);
     //on form closed event
     //Calls the unloading code (including database saving and winform object state saving) of all required objects.
     //If you want to upload objects separately or perform a special upload, copy the code
     //from the body of this method and modify it.
     MainAppUtils.DestroyApp();
 }
コード例 #2
0
ファイル: Program.cs プロジェクト: trung85/FrwSimpleWinCRUD
 private static void Form_FormClosed(object sender, FormClosedEventArgs e)
 {
     try
     {
         MainAppUtils.DestroyApp();
     }
     catch (Exception ex)
     {
         Log.ShowError(ex);
     }
 }