workflow foundation - Windows work flow edit rule set xml through C# -


we have existing rule sets defined in our system huge in number. need take of of them , build new rule sets. instead of doing manually , editing each rule set, programmatically edit them , update rule set xml in database. able retrieve condition , make changes cant convert rule set. inputs on achieving this.

foreach (var condition in rulesets.rules) {     system.workflow.activities.rules.rulecondition modifiedcondition;      if (condition.condition.tostring().contains("example"))     {         //unable achieve this.         modifiedcondition= condition.condition.tostring().replace("example", "example2");     }                      } 

you can't rewrite condition modifying textual representation. need modify existing condition or create new condition via codedom.

kavita's blog has basic tutorial on manipulating rules via codedom. see this forum discussion.


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -