private void btnActiveDetails_Click(object sender, RoutedEventArgs e)
        {
            popupgrid.IsOpen = true;
            if (string.IsNullOrEmpty(StartDate) || string.IsNullOrEmpty(EndDate))
            {
                BMC.Presentation.CashDeskManager.MessageBox.showBox("Not a valid Date Range");
            }

            CActiveTicketsxaml objActiveTickets = new CActiveTicketsxaml("0", StartDate, EndDate,
            StartTime, EndTime);


            exceptiongrid.Children.Add(objActiveTickets);
            //objActiveTickets.Margin = new Thickness(exceptiongrid.Width/8, 50, 0, 0);
            objActiveTickets.Margin = new Thickness(0);
        }
        private void btnActiveDetails_Click(object sender, RoutedEventArgs e)
        {
            try
            {
                CActiveTicketsxaml objActiveTickets = null;
                objActiveTickets = new CActiveTicketsxaml("0", StartDate, EndDate, 0);


                objActiveTickets.Owner = MessageBox.parentOwner;
                objActiveTickets.ShowDialogEx(this);
            }
            catch (Exception ex)
            {
                ExceptionManager.Publish(ex);
            }
        }