private void btnConfirm_Click(object sender, RoutedEventArgs e)
        {
            if (string.IsNullOrEmpty(txtAdvanceToRetailer.Text))
            {
                MessageBox.ShowBox("MessageID370", BMC_Icon.Information);
                return;
            }

            decimal dAdvanceToRetailer = 0.0M;

            if (!CheckForValidAdvanceToRetailValue(out dAdvanceToRetailer))
            {
                MessageBox.ShowBox("MessageID434", BMC_Icon.Information);
                return;
            }

            System.Windows.Forms.DialogResult dr = MessageBox.ShowBox("MessageID371", BMC_Icon.Question, BMC_Button.YesNo);

            if (dr.ToString() == "Yes")
            {
                //Update advance retailer value
                UpdateAdvanceRetailer();

                //Calculate the retailer negative net

                CalculateRetailerNegative();

                var oReports = new CollectionBatchReports(_BatchNo, this);
                oReports.ShowDialog();
            }
        }
        private void btnConfirm_Click(object sender, RoutedEventArgs e)
        {
            if (string.IsNullOrEmpty(txtAdvanceToRetailer.Text))
            {
                MessageBox.ShowBox("MessageID370", BMC_Icon.Information);
                return;
            }

            decimal dAdvanceToRetailer = 0.0M;
            if (!CheckForValidAdvanceToRetailValue(out dAdvanceToRetailer))
            {
                MessageBox.ShowBox("MessageID434", BMC_Icon.Information);
                return;
            }

            System.Windows.Forms.DialogResult dr = MessageBox.ShowBox("MessageID371", BMC_Icon.Question, BMC_Button.YesNo);

            if (dr.ToString() == "Yes")
            {
                //Update advance retailer value
                UpdateAdvanceRetailer();

                //Calculate the retailer negative net

                CalculateRetailerNegative();

                var oReports = new CollectionBatchReports(_BatchNo,this);
                oReports.ShowDialog();
            }
            
        }