Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
7 replies
Subscribers
9 subscribers
Views
3807 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
User Interface
I am using below code for a checkbox a!checkboxField( label:
poojas
over 9 years ago
I am using below code for a checkbox
a!checkboxField(
label: rule!medMgmt_Translate(local!bundle,"Contacts_informed_of_Case_Closure"),
labelPosition: local!labelPos,/*"Contacts informed of Case Closure",*/
instructions: "All appropriate contacs have been infomred of case closure and advised to contact Claims Adjuster with any further questions.",
choiceLabels: {""},
choiceValues: {true},
value: ri!cdtFinalActionPlan.boolContactInformed,
saveInto: ri!cdtFinalActionPlan.boolContactInformed
Getting following error when false value comes from DB
Expression evaluation error in rule 'inf_medmgmt_finalactionplan' at function a!checkboxField [line 160]: A checkbox component [label=“Contacts informed of Case Closure”] has an invalid value for “value”. All selected values must be present in the choiceValues array, but value was false and choiceValues was true.
What changes should I do in C...
OriginalPostID-157077
OriginalPostID-157077
Discussion posts and replies are publicly visible
0
poojas
over 9 years ago
...hoice value and label?
Thanks,
Pooja
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
neelimaj
over 9 years ago
Pooja,
Please use radio button if you need true/ false condition to work. Check box cannot take boolean values. Or you can use "true" instead of true.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Tim
Certified Lead Developer
over 9 years ago
The issue is with how the null value is evaluated in your CDT, try this:
if(rule!APN_isBlank(ri!cdtFinalActionPlan.boolContactInformed), null, ri!cdtFinalActionPlan.boolContactInformed)
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sikhivahans
over 9 years ago
@poojas Please find attached the snippet which lets you know how you can make checkbox accept boolean values. You can pull the checkbox component and its associated logic into an expression and turn it into a reusable component. Hope it gives you some leads over the issue.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
poojas
over 9 years ago
Thanks a lot sikhivahans. Your code works for me.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sikhivahans
over 9 years ago
@poojas No worries.!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
leslies331
over 9 years ago
or you can just think of it at true() or null and treat null as false
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel