Example #1
0
    private void Fill_GridRuleParameters_MasterRulesView(decimal RuleGroupID, decimal RuleDataRangeID)
    {
        string[] retMessage = new string[4];
        IList <RuleParameter> RuleParametersList = null;

        try
        {
            BRuleViewer RulesViewerBusiness = new BRuleViewer(RuleGroupID);
            RuleParametersList = RulesViewerBusiness.GetAllRuleParameters(RuleDataRangeID);
            this.GridRuleParameters_MasterRulesView.DataSource = RuleParametersList;
            this.GridRuleParameters_MasterRulesView.DataBind();
        }
        catch (UIValidationExceptions ex)
        {
            retMessage = this.exceptionHandler.HandleException(this.Page, ExceptionTypes.UIValidationExceptions, ex, retMessage);
            this.ErrorHiddenField_RuleParameters.Value = this.exceptionHandler.CreateErrorMessage(retMessage);
        }
        catch (UIBaseException ex)
        {
            retMessage = this.exceptionHandler.HandleException(this.Page, ExceptionTypes.UIBaseException, ex, retMessage);
            this.ErrorHiddenField_RuleParameters.Value = this.exceptionHandler.CreateErrorMessage(retMessage);
        }
        catch (Exception ex)
        {
            retMessage = this.exceptionHandler.HandleException(this.Page, ExceptionTypes.Exception, ex, retMessage);
            this.ErrorHiddenField_RuleParameters.Value = this.exceptionHandler.CreateErrorMessage(retMessage);
        }
    }
Example #2
0
        public void GetAllRuleParametersTest()
        {
            IList <RuleParameter> param = businessRuleViwer.GetAllRuleParameters(ADOAssignRuleParam1.ID);

            Assert.AreEqual(param.Count, 2);
        }