private void Afr_ErrorHandler(string message) { UISync.Execute(() => { MessageBox.Show(this, "Connection Failed"); }); afr.Close(); }
private void Vfr_NewFrame(object sender, Sources.NewFrameEventArgs e) { vfr.NewFrame -= Vfr_NewFrame; if (e.Frame == null) { UISync.Execute(() => { MessageBox.Show(this, "Connection Failed"); }); } else { UISync.Execute(() => { MessageBox.Show(this, "Connected!"); }); } vfr.Close(); }