You are viewing limited content. For full access, please sign in.

Question

Question

Set Business Process Variables On a CheckBox Clears Existing Values

asked on February 28, 2023

Hello all,

 

When I set one or more checkbox values using "Set Business Process Variables" in Workflow it clears all other boxes checked.  Is this the expected behavior or am I just setting them incorrectly.  I'm setting them like My_Favorite_Color=Red,Green,Blue

Thoughts?

 

0 0

Answer

SELECTED ANSWER
replied on February 28, 2023

I've never been able to get it to work that way.  But here's how to do it with a multi-value token:

Use the Assign Token Values activity to set-up a multi-value token and list your checkbox values there.

Then in the "Set Business Process Variables" activity, you'll assign the token to the field, with comma separated index:

It'll look like this in the "Starting Variable Values" section: 

My_Favorite_Color=%(Checkbox Values#[, ]#)

 

0 0
replied on February 28, 2023

Okay,  yeah, I'm trying to preserve the currently selected values AND have the workflow add some selections.  So, the following assignment appears to be working.  It reselects the checkboxes that are already selected and makes sure the final 2 hardcoded values are selected.

Flavor_Choice=%(RetrieveBusinessProcessVariables_Flavor_Choice#[, ]#),Cookies_and_Cream,Vanilla

1 0
replied on February 28, 2023

Glad to hear you got it working!

0 0
replied on February 28, 2023

Many thanks!

0 0

Replies

replied on February 28, 2023

Are you saying you want your values merged into the existing selected checkboxes for the fields? That's not how it works. Workflow submits a new set of values for the specified fields.

0 0
replied on February 20, 2024

Hi All,

 

Want to hear, I have the same, but I want to update Checkboxes in a collection. I can get it working on a single item in Workflow. 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.