3

I'm using the RuleSetDialog to create rules for a validation module and storing the resulting xml in the database. Is there any way to programatically create rules their conditions based on a code string?

This post gave me some insight: Creating rules programmatically in WFF

However I need something a lot simplier like

RuleCondition rc = new RuleCondition("this.ErrorsDetected==true", "Console.WriteLine(ERROR_MSG)", "DoNothing()";

Is there any way to achieve this?

Thanks in advance Bruno

Community
  • 1
  • 1
Bruno
  • 445
  • 4
  • 10

1 Answers1

1

I think you can't achieve that without some hacking of WF as described here.

Basic idea is to use reflection to get same functionality as with RuleSetDialog

aron
  • 1,874
  • 5
  • 23
  • 29