// // Event handlers // -------------- // // Name: ingresDataAdapter5_RowUpdated // // Description: // Set a timer to reload the data set. // The data used to populate the DataGridView is composed from an // inner join query. Updating through the DataGridView requires // that on commit the content of DataGridView needs to be // refreshed to populate all fields in the new row. // This event handler starts a timer that invokes a refresh by // issuing a query with the insert data as the set of query // parameters. // // Input: // sender Ingres data adapter. // e event argument. // Output: // None. // // Returns: // None. // // History: // 02-Oct-2006 ([email protected]) // Created. private void ingresDataAdapter5_RowUpdated(object sender, Ingres.Client.IngresRowUpdatedEventArgs e) { if (e.StatementType == StatementType.Insert) { // Inserted row needs to be updated, a datagridview with // only one row will treat updates as new inserts since the // RowState doesn't change. // Also the populating query needs to be rerun to get // joined information. System.Windows.Forms.Timer t = new System.Windows.Forms.Timer(); t.Tick +=new EventHandler(routeReload); t.Interval = 50; t.Enabled = true; } }
/* ** Name: trace ** ** Description: ** Write XID to trace log. ** ** Input: ** trace Internal tracing. ** ** Output: ** None. ** ** Returns: ** void. ** ** History: ** 11-Apr-01 (gordy)*/ internal virtual void trace(Ingres.Utility.ITrace itrace) { if (itrace == null) return; switch (type) { case XID_INGRES: itrace.write("II XID: 0x" + System.Convert.ToString(xid, 16)); break; case XID_XA: itrace.write("XA XID: FormatId = 0x" + System.Convert.ToString(fid, 16)); itrace.write("GlobalTransactionId: "); itrace.hexdump(gtid, 0, gtid.Length); itrace.write("BranchQualifier: "); itrace.hexdump(bqual, 0, bqual.Length); break; } return ; }