Ejemplo n.º 1
0
        void _mrsClient_GetAreaSurchargeCompleted(object sender, GetAreaSurchargeCompletedEventArgs e)
        {
            if (e.Error == null)
            {
                if (e.Result[0] == 1)
                {
                    MessageBoxResult confirm = MessageBox.Show("There is a " + e.Result[1].ToString("c") + " surcharge, would you like to merge it into home price?\r\nClick OK to merge or otherwise click Cancel.", "", MessageBoxButton.OKCancel);
                    if (confirm == MessageBoxResult.OK)
                    {
                        System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=1&type=" + _printType + "&EstimateRevisionId=" + _estimateRevisionId.ToString(), UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                    }
                    else
                    {
                        System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=0&type=" + _printType + "&EstimateRevisionId=" + _estimateRevisionId.ToString(), UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                    }
                }
                else
                {
                    System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=0&type=" + _printType + "&EstimateRevisionId=" + _estimateRevisionId.ToString(), UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                }

                this.DialogResult = true;
                CloseRadWindow();
            }
            else
            {
                ExceptionHandler.PopUpErrorMessage(e.Error, "GetAreaSurchargeCompleted");
            }
        }
Ejemplo n.º 2
0
        void _mrsClient_GetAreaSurchargeCompleted(object sender, GetAreaSurchargeCompletedEventArgs e)
        {
            string printversion = "FULLDETAILS";
            string includestd   = "0";

            if ((bool)chkIncludeSTD.IsChecked)
            {
                includestd = "1";
            }

            if ((bool)rdlump.IsChecked)
            {
                printversion = "lUMPSUM";
            }
            else if ((bool)rdsummary.IsChecked)
            {
                printversion = "FULLSUMMARY";
            }
            else
            {
                printversion = "FULLTOTAL";
            }
            if (e.Error == null)
            {
                if (e.Result[0] == 1)
                {
                    MessageBoxResult confirm = MessageBox.Show("There is a " + e.Result[1].ToString("c") + " surcharge, would you like to merge it into home price?\r\nClick OK to merge or otherwise click Cancel.", "", MessageBoxButton.OKCancel);
                    if (confirm == MessageBoxResult.OK)
                    {
                        System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=1&type=customer&version=" + printversion + "&EstimateRevisionId=" + _estimateRevisionId.ToString() + "&IncludeProductNameAndCode=" + _includeProductNameAndCode + "&IncludeUOMAndQuantity=" + _includeUOMAndQuantity + "&includeSpecifications=" + _includeSpecifications + "&includestd=" + includestd, UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                    }
                    else
                    {
                        System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=0&type=customer&version=" + printversion + "&EstimateRevisionId=" + _estimateRevisionId.ToString() + "&IncludeProductNameAndCode=" + _includeProductNameAndCode + "&IncludeUOMAndQuantity=" + _includeUOMAndQuantity + "&includeSpecifications=" + _includeSpecifications + "&includestd=" + includestd, UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                    }
                }
                else
                {
                    System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=0&type=customer&version=" + printversion + "&EstimateRevisionId=" + _estimateRevisionId.ToString() + "&IncludeProductNameAndCode=" + _includeProductNameAndCode + "&IncludeUOMAndQuantity=" + _includeUOMAndQuantity + "&includeSpecifications=" + _includeSpecifications + "&includestd=" + includestd, UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                }

                this.DialogResult = true;
                CloseRadWindow();
            }
            else
            {
                ExceptionHandler.PopUpErrorMessage(e.Error, "GetAreaSurchargeCompleted");
            }
        }
Ejemplo n.º 3
0
 void _mrsClient_GetAreaSurchargeCompleted(object sender, GetAreaSurchargeCompletedEventArgs e)
 {
     if (e.Error == null)
     {
         if (e.Result[0] == 1)
         {
             SurchargeMessage = "There is a " + e.Result[1].ToString("c") + @" surcharge, merge it into home price";
             SurchargeVisible = Visibility.Visible;
         }
         else
         {
             SurchargeMessage = "";
             SurchargeVisible = Visibility.Collapsed;
         }
     }
     else
     {
         ExceptionHandler.PopUpErrorMessage(e.Error, "GetAreaSurchargeCompleted");
     }
 }
Ejemplo n.º 4
0
        void _mrsClient_GetAreaSurchargeCompleted(object sender, GetAreaSurchargeCompletedEventArgs e)
        {
            if (e.Error == null)
            {
                if (radioButtonInternalCopy.IsChecked == true)
                {
                    _printType = "internal";
                }
                else if (radioButtonFinalConstructionCopy.IsChecked == true)
                {
                    _printType = "final";
                }
                else
                {
                    _printType = "supplier";
                }
                if (e.Result[0] == 1)
                {
                    MessageBoxResult confirm = MessageBox.Show("There is a " + e.Result[1].ToString("c") + " surcharge, would you like to merge it into home price?\r\nClick OK to merge or otherwise click Cancel.", "", MessageBoxButton.OKCancel);
                    if (confirm == MessageBoxResult.OK)
                    {
                        HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=1&type=" + _printType + "&IncludeProductNameAndCode=" + _includeProductNameAndCode + "&IncludeUOMAndQuantity=" + _includeUOMAndQuantity + "&includeSpecifications=" + _includeSpecifications + "&EstimateRevisionId=" + _estimateRevisionId.ToString(), UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                    }
                    else
                    {
                        HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=0&type=" + _printType + "&IncludeProductNameAndCode=" + _includeProductNameAndCode + "&IncludeUOMAndQuantity=" + _includeUOMAndQuantity + "&includeSpecifications=" + _includeSpecifications + "&EstimateRevisionId=" + _estimateRevisionId.ToString(), UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                    }
                }
                else
                {
                    HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=0&type=" + _printType + "&IncludeProductNameAndCode=" + _includeProductNameAndCode + "&IncludeUOMAndQuantity=" + _includeUOMAndQuantity + "&includeSpecifications=" + _includeSpecifications + "&EstimateRevisionId=" + _estimateRevisionId.ToString(), UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
                }

                this.DialogResult = true;
                CloseRadWindow();
            }
            else
            {
                ExceptionHandler.PopUpErrorMessage(e.Error, "GetAreaSurchargeCompleted");
            }
        }