Exemple #1
0
        private void button_ok_Click(object sender, EventArgs e)
        {
            if (!Globals.isValidBarcodePrefix(this.textBox_barcode.Text))
            {
                MessageBox.Show("バーコード識別子が不正です。0-9の数字を2文字指定してください。");
                this.textBox_barcode.SelectAll();
                this.textBox_barcode.Focus();
                return;
            }

            DbConfig.setValue("bumonname", this.textBox_bumon.Text);
            DbConfig.setValue("companyname", this.textBox_company.Text);
            DbConfig.setValueInt("symbolcolor_argb", this.pictureBox1.BackColor.ToArgb());
            DbConfig.setValueInt("bumontextcolor_argb", this.pictureBox2.BackColor.ToArgb());
            DbConfig.setValue("barcodeprefix", this.textBox_barcode.Text);
            DbConfig.setValueBool("itemname_imeon", this.checkBox_imeon.Checked);
            DbConfig.setValueBool("entertotab", this.checkBox_entertotab.Checked);

            this.DialogResult = DialogResult.OK;
            this.Close();
        }