private void buttonDebugLedOn_Click(object sender, EventArgs e) { byte ledNum; try { ledNum = Convert.ToByte(textBoxDebugLedOn.Text); } catch (Exception) { MessageBox.Show("Insert valid value!"); return; } com.AppendLedOn(ledNum); textBoxDebugInstructionPool.Text += "LedOn(" + ledNum + ")\r\n"; FormCustomConsole.WriteLine("LedOn(" + ledNum + ")"); }