How can I reset a radio button list selection in an action when its value was set in previous action?

Issue

How can I reset a radio button list selection in an action when its value was set in previous action?

Solution

There are two ways to do this.

Method 1

Set up an IN parameter for the radio button list control and enter a space as a TEXT value. When WorkflowGen renders the web form, it will see that the expected value " " is not available and reset the selection. This is suitable if you need to always reset the value at a certain action (such as when launching an approval action subsequent times, you might always want to clear that it was rejected previously and force a new response).

Method 2

In code-behind, add .NET code to reset its value during the webpage’s Page_Load event.

if (YOUR_CONDITION)
{ this.YOUR_RADIO_BUTTON_LIST.SelectedIndex = -1; }

This is suitable for situations that require a radio button list reset based on certain conditions (such as not resetting when the approval action is initiated from draft mode).