Example #1
0
        private void tbDecimal_TextChanged(object sender, System.EventArgs e)
        {
            // To hold our converted unsigned type value
            uint uiDecimal = 0;

            try
            {
                uiDecimal = checked ((uint)System.Convert.ToByte(((TextBox)sender).Text));
            }
            catch (System.OverflowException)
            {
                this.btnOK.Enabled = false;
                return;
            }
            catch (System.FormatException)
            {
                this.btnOK.Enabled = false;
                return;
            }
            this.btnOK.Enabled = true;
            if (tb1.Text.Length > 0 && tb2.Text.Length > 0 && tb3.Text.Length > 0)
            {
                _current_val = new EIBAddress(this.tb1.Text + "/" + this.tb2.Text + "/" + this.tb3.Text);
            }
        }
Example #2
0
 public EIBAddressForm()
 {
     InitializeComponent();
     _current_val = new EIBAddress();
 }