// Sherlock on error event. // If Sherlock encounters an error which halts execution // this event handler is called. private void OnDalsaRunErrorEvent(I_EXEC_ERROR sherlockError) { // Because the Sherlock object was created // on a different thread I have to marshall // all messages from Sherlock back to the main // UI thread. _synchronizationContext.Post(callback => OnRunError(this, new RunErrorEventArgs(sherlockError)), null); }
/// <summary> /// Custom event class for raising a Sherlock error message. /// </summary> public RunErrorEventArgs(I_EXEC_ERROR sherlockError) { _sherlockError = sherlockError.ToString( ); }
/// <summary> /// Custom event class for raising a Sherlock error message. /// </summary> public RunErrorEventArgs( I_EXEC_ERROR sherlockError ) { _sherlockError = sherlockError.ToString( ); }