CodeTV.WinLIRCMappingEditorForm.checkBoxLearn_CheckedChanged C# (CSharp) Method

checkBoxLearn_CheckedChanged() private method

private checkBoxLearn_CheckedChanged ( object sender, EventArgs e ) : void
sender object
e EventArgs
return void
        private void checkBoxLearn_CheckedChanged(object sender, EventArgs e)
        {
            if (this.checkBoxLearn.Checked)
            {
                if (!this.winLIRC.Start())
                {
                    MessageBox.Show(string.Format("Cannot connect to WinLIRC server: {0}:{1}", this.winLIRC.HostName, this.winLIRC.Port));
                    this.checkBoxLearn.Checked = false;
                }
            }
            else
                this.winLIRC.Start();
        }