I have a workflow where I set the Comments to Required on Rejection. Everything was working OK until I customized the form with Nintex Forms. Is this the expected behavior and I should put my own rule in if the form is customized? Thanks!
Hello Igor Karon -
Check out Using validation rules to ensure a comments box is not left empty
If you use Nintex Forms you will need to add in a rule on the Comments field.
The rule will be straightforward:
and(isNullOrEmpty({Self}),Decision==2)
Here is the outcome in action:
Hope this helps!
just to add to this, I have had occasions before where the response value (Decision) is not the expected 2 (this can happen when you change the outcomes on your flexi task action). if what Jesse suggests doesn't work, add a calculated field to your form for de-bugging purposes outputting the value from decision so that you can see how to modify this bit above:
and(isNullOrEmpty({Self}),Decision==2)
Thanks
Cassy
And to add even more to this:
You also have to be aware that in the preview mode the decision will always return "-1". If you published the form and use it in your process, the outcome will be the correct number. If you want to know, which numbers stands for your outcomes, you can have a look at your Nintex DB (if you have sufficient permissions).
As you can see, in my case there are multiple custom outcomes. The "Id" value, is what will be returned in your form.
Regards
Philipp
Thank you all for all the valuable information!
One more caveat to be aware of - these outcomes/IDs can vary across your site collections and farms. They are set in the ConfiguredOutcomes table. If you notice differences in behaviour between your dev/test/prod etc farms, that's why. Only way to be certain is to interrogate that table for each environment and adjust accordingly (maybe use a constant).
Cheers,
Chris
To add even a bit more to this..
You can find the outcome # in the web page's HTML code when you run the workflow. For non-farm admins this can be really effective.
So if you're using IE..
- Open the task form
- Open the developer tools (F12)
- Enable select element
- Select the radio button for the outcome.
- It'll select something in the code, look for the INPUT tag. It'll have a name, disabled, id, type, and value. The value is the # for your custom outcome, and you'll also notice that Approve is 1 and Reject is 2.
Cheers
Josh
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.