コード例 #1
0
ファイル: WATR_XBeeDevice.cs プロジェクト: JCritchfield/WATR
 //Called when the log form is closed
 void log_FormClosing(object sender, System.Windows.Forms.FormClosingEventArgs e)
 {
     //Remove the log handler; it'll cause problems otherwise..
     log.FormClosing -= log_FormClosing;
     //Null the reference
     log = null;
 }
コード例 #2
0
ファイル: WATR_XBeeDevice.cs プロジェクト: JCritchfield/WATR
 //Called by the backend in response to a log request
 public void UpdateLogRecord(DataTable record)
 {
     //Make sure a log book doesn't exist first...
     if (log == null)
     {
         log = new WATR_Logbook();
         //Add an event handler for the log
         log.FormClosing += log_FormClosing;
         log.Text += " - " + this.Identifier;
         log.SetDataSource(record);
         log.Show();
     }
 }