コード例 #1
0
ファイル: InvoiceEdit.xaml.cs プロジェクト: OneSmugPug/Denovo
        private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            CbClient.Focus();

            TxtInvoiceNumber.Text = invNumber;

            TxtBillAmount.SelectionStart = TxtBillAmount.Text.Length;
            TxtDrawingFee.SelectionStart = TxtDrawingFee.Text.Length;

            CbFinalized.IsChecked = false;

            LoadClients();

            LoadInvoice();
        }
コード例 #2
0
ファイル: InvoiceAdd.xaml.cs プロジェクト: OneSmugPug/Denovo
        private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            CbClient.Focus();
            TxtBillAmount.Text = "0.00";
            TxtCommDue.Text    = "0.00";
            TxtDFAmount.Text   = "0.00";
            TxtDrawingFee.Text = "11.00";

            if (decimal.TryParse(TxtDrawingFee.Text.Replace(",", "").Replace(".", "").TrimStart('0'), out decimal result))
            {
                result    /= 10000;
                drawingFee = result;
            }

            TxtBillAmount.SelectionStart = TxtBillAmount.Text.Length;
            TxtDrawingFee.SelectionStart = TxtDrawingFee.Text.Length;

            DtpDate.SelectedDate  = DateTime.Now;
            CbFinalized.IsChecked = false;

            LoadClients();

            GetInvoiceNumber();
        }