Пример #1
0
        /// <summary>
        /// This event is fired on click of the submit button on the dialog,
        /// this would validate the parameters accordingly and on success would initiate adding
        /// of the parameters to the given service parameters
        /// </summary>
        /// <param name="sender">submit button</param>
        /// <param name="e">Event Data</param>
        private void OnBtnSubmitClick(object sender, RoutedEventArgs e)
        {
            BlastParameters serviceParam = new BlastParameters();
            bool            valid        = this.AddServiceParams(ref serviceParam, this.firstStk);

            if (valid)
            {
                valid = this.AddServiceParams(ref serviceParam, this.secondStk);
            }

            if (valid)
            {
                valid = this.AddServiceParams(ref serviceParam, this.thirdColumnParams);
            }

            if (valid)
            {
                valid = this.AddServiceParams(ref serviceParam, this.commonParamsStk);
            }

            if (valid && this.serviceParams.Visibility == Visibility.Visible)
            {
                valid = this.AddServiceParams(ref serviceParam, this.serviceParams);
            }

            if (valid)
            {
                ConfigParameters configParams = new ConfigParameters();
                configParams.UseBrowserProxy = (bool)this.chkUseBrowerProxy.IsChecked;
                configParams.DefaultTimeout  = 1;

                valid = this.AddConfigurationParameter(configParams, this.stkConfigurationParams);

                WebServiceInputEventArgs args = new WebServiceInputEventArgs(serviceParam, this.serviceName, configParams);
                this.WebServiceInputArgs = args;
                if (this.ExecuteSearch != null && valid)
                {
                    this.ExecuteSearch.Invoke(this, args);
                    this.Close();
                }
            }

            if (valid)
            {
                this.Close();
            }
        }
Пример #2
0
        /// <summary>
        /// This event is fired on click of the submit button on the dialog,
        /// this would validate the parameters accordingly and on success would initiate adding
        /// of the parameters to the given service parameters
        /// </summary>
        /// <param name="sender">submit button</param>
        /// <param name="e">Event Data</param>
        private void OnBtnSubmitClick(object sender, RoutedEventArgs e)
        {
            var  serviceParam = new BlastRequestParameters();
            bool valid        = this.AddServiceParams(ref serviceParam, this.firstStk);

            if (valid)
            {
                valid = this.AddServiceParams(ref serviceParam, this.secondStk);
            }

            if (valid)
            {
                valid = this.AddServiceParams(ref serviceParam, this.thirdColumnParams);
            }

            if (valid)
            {
                valid = this.AddServiceParams(ref serviceParam, this.commonParamsStk);
            }

            if (valid && this.serviceParams.Visibility == Visibility.Visible)
            {
                valid = this.AddServiceParams(ref serviceParam, this.serviceParams);
            }

            if (valid)
            {
                var args = new WebServiceInputEventArgs(this.serviceName, serviceParam);
                this.WebServiceInputArgs = args;
                if (this.ExecuteSearch != null)
                {
                    this.ExecuteSearch.Invoke(this, args);
                    this.Close();
                }
                else
                {
                    this.Close();
                }
            }
        }
Пример #3
0
        /// <summary>
        /// This event is fired on click of the submit button on the dialog,
        /// this would validate the parameters accordingly and on success would initiate adding
        /// of the parameters to the given service parameters
        /// </summary>
        /// <param name="sender">submit button</param>
        /// <param name="e">Event Data</param>
        private void OnBtnSubmitClick(object sender, RoutedEventArgs e)
        {
            var serviceParam = new BlastRequestParameters();
            bool valid = this.AddServiceParams(ref serviceParam, this.firstStk);

            if (valid)
                valid = this.AddServiceParams(ref serviceParam, this.secondStk);

            if (valid)
                valid = this.AddServiceParams(ref serviceParam, this.thirdColumnParams);

            if (valid)
                valid = this.AddServiceParams(ref serviceParam, this.commonParamsStk);

            if (valid && this.serviceParams.Visibility == Visibility.Visible)
                valid = this.AddServiceParams(ref serviceParam, this.serviceParams);

            if (valid)
            {
                var args = new WebServiceInputEventArgs(this.serviceName, serviceParam);
                this.WebServiceInputArgs = args;
                if (this.ExecuteSearch != null)
                {
                    this.ExecuteSearch.Invoke(this, args);
                    this.Close();
                }
                else
                    this.Close();
            }
        }