RegExValidationStep does not load from context

Jul 9, 2008 at 2:31 PM
The RegExValidation step will not load values from the context in the <ValidationRegEx> Nodes. Here is a a change to RegExValidationStep.cs to fix this.

Change ExecuteValidation function starting on line 68 to:

public void ExecuteValidation(Stream data, XmlNode validatorConfig, Context context)
        {
               XmlNodeList validationNodes = validatorConfig.SelectNodes("ValidationRegEx");

            foreach (XmlNode validationNode in validationNodes)
            {
                if (0 != validationNode.Attributes.Count)
                {
                    this.validationRegExs.Add(context.GetValue(validationNode.Attributes.Item(0).InnerText));
                }
                else
                {
                    this.validationRegExs.Add(validationNode.InnerText);
                }
            }

            ExecuteValidation(data, context);
        }