Example #1
0
        private void btSearch_Click(object sender, RoutedEventArgs e)
        {
            SearchAccount go = new SearchAccount();

            go.sendAcc    = txtaccCode.Text;
            go.sendItem   = showtxtaccItem.Text;
            go.sendStatus = showtxtaccStatus.Text;
            go.ShowDialog();

            txtaccCode.Text       = go.sendAcc;
            showtxtaccItem.Text   = go.sendItem;
            showtxtaccStatus.Text = go.sendStatus;

            if (showtxtaccStatus.Text == "รายรับ")
            {
                txtPay.IsEnabled = false;
                txtRub.IsEnabled = true;
            }

            if (showtxtaccStatus.Text == "รายจ่าย")
            {
                txtPay.IsEnabled = true;
                txtRub.IsEnabled = false;
            }
        }
Example #2
0
        private void Search_Click(object sender, RoutedEventArgs e)
        {
            SearchAccount go = new SearchAccount();

            go.sendAcc    = txtAcc.Text;
            go.sendItem   = txtItem.Text;
            go.sendStatus = typeComboBox.Text;
            go.ShowDialog();

            txtAcc.Text  = go.sendAcc;
            txtItem.Text = go.sendItem;
            typeComboBox.SelectedItem = go.sendStatus;
        }