Goal: name1, name2, name3 (show and hide comas in between and names if they are selected)
Default is N/A if no names are selected
What I have tried: if(isnull({pv!process.name1,pv!process.name2,pv!process.name3}), "N/A","") & if(isnull(pv!process.name1), "",", "& pv!process.name1) & if(isnull(pv!process.name2), "", ", "&pv!process.name2) & if(isnull(pv!process.name3), "", ", "&pv!process.name3))
Discussion posts and replies are publicly visible
Hi,
You can use the following logic.
a!localVariables( local!name: if( all( fn!isnull, { ri!name1, ri!name2, ri!name3 } ), "N/A", concat( if( a!isNullOrEmpty(ri!name1), "", ri!name1 ), if( a!isNullOrEmpty(ri!name2), "", if( a!isNullOrEmpty(ri!name1), ri!name2, { ", ", ri!name2 } ) ), if( a!isNullOrEmpty(ri!name3), "", if( and( a!isNullOrEmpty(ri!name1), a!isNullOrEmpty(ri!name2) ), ri!name3, { ", ", ri!name3 } ) ) ) ), local!name )
oh sorry maybe I wasn't clear but this was for a email, does the same logic apply?
Yes, It will work. Create an expression rule with this logic and call that rule in your email node.
ex: rule!returnName( name1: pv!name1, name2: pv!name2, name3: pv!name3 )