Method Community

 

Using actions with Checkboxes

Last post 03-29-2013 11:32 AM by Method_Ashur. 6 replies.
Page 1 of 1 (7 items)
Sort Posts: Previous Next
  • 03-29-2012 12:15 PM

    Using actions with Checkboxes

    I've created a checkbox object that I want to tie to a boolean field, IsComplete. When the box is checked, I want IsComplete to be marked "Yes", and when it is unchecked to be marked "No". 

    Since the trigger event for a checkbox is "click", I have to create conditional statements to check to first see whether it was checked or unchecked before it was clicked on. So, two questions:

    1. When defining the conditional statement, I'll select the checkbox value from the screen, and compare it ("is equal to")... what? Should I "type in" the value? What are the values of a checkbox? "Yes" and "No", or "True" and "False"? 

     

    2. So say I've made my conditional statements for the "click" trigger event, that take the checkbox value from the screen:  WIll the conditional statement look at the value of the box before it was clicked, or after

     

    By the way, this object-specific info should totally be in the help center/object guide!

  • 03-29-2012 1:59 PM In reply to

    Re: Using actions with Checkboxes

    Answer

    Hi smohyee,

    smohyee:
    When defining the conditional statement, I'll select the checkbox value from the screen, and compare it ("is equal to")... what? Should I "type in" the value? What are the values of a checkbox? "Yes" and "No", or "True" and "False"? 

    You can actually use either of those options. "Yes" and "No", or "True" and "False".

    smohyee:
    So say I've made my conditional statements for the "click" trigger event, that take the checkbox value from the screen:  WIll the conditional statement look at the value of the box before it was clicked, or after

    The statement will look at the value of the box after it is checked or un-checked. Feel free to test this by adding a 'Show Message' action within each of the conditions.

    If True…show True or If False…show False

    Can I ask why you are using the object to update the field? Why not just drag the field itself on the screen and use that? I'm sure you have your reasons I'm just being curious.

    Need more help? Ask us about Method consulting services.

    Valbon Shabani
    Director of Education
    Method Integration Inc.
    Toll Free: 1.888.925.6238 ext. 715
    Local and overseas: 416.847.0400 ext. 715
    Fax: 416.640.6027
    E-mail: valbon@method.me
    Website: http://www.linkedin.com/in/valbon
  • 03-30-2012 11:58 AM In reply to

    Re: Using actions with Checkboxes

    Thanks for the response Valbon. I'll keep the "Show Message" action in mind for future value testing.

    Your question is a very good one! I had assumed the IsComplete field would be a text field (don't ask why) where the Yes/No value would have to be typed in, but after you asked I went and looked at the field object and facepalmed. 

  • 03-30-2012 12:51 PM In reply to

    • Rolf
    • Top 50 Contributor
    • Joined on 09-18-2011
    • Posts 109

    Re: Using actions with Checkboxes

    Answer

    smohyee,

    I've used numerous check boxes as part of a customer application process that employees fill in. With a default of unchecked (or no) I never knew whether the employees had actually considered that field or not, and have now switched to a dropdown with Yes, No, or blank choices(default is blank).  This provides assurance that 'No' does mean no.

    Rolf

  • 03-30-2012 1:27 PM In reply to

    Re: Using actions with Checkboxes

    Rolf: That's a good point. A third option indicating no deliberate change was made would certainly help in some cases. Thanks!

  • 03-28-2013 9:20 PM In reply to

    Re: Using actions with Checkboxes

    I created a checkbox field but I want a message to appear when the checkbox is checked.  No message pop-up when it is not checked even by clicking the box to uncheck it.  How do I do this?  Below are the actions that I've added so far but it is not working properly:

    1. Event: Click:  Start Conditional Statement  Value 1:  Value From Screen  Checkbox Field  Equal To  Value 2: Type In  True

    2. Event: Click:  Show Message  Typed my message  Selected Provide Yes/No option to user? 'Ok' assigns True. 'Cancel' assigns False.

    3. Event: Click:  End Conditional Statement

    Right now when I check the box no message appears.  Also, when I delete the conditional statements and click 'No' when the message appears the checkbox does not revert to a false value.

  • 03-29-2013 11:32 AM In reply to

    Re: Using actions with Checkboxes

    Answer

    Hi Steven,

    I created the same actions you have and it works correctly. Message appears when the box is clicked to set the value to True, but not when clicking and setting value to False. Also when the message pops-up, when I select 'Ok' or 'Cancel' the correct values are assigned to the action result, i.e. YES or NO.

    Can you double check your actions to confirm everything is setup as you stated in your first post. Test it again and let me know what happens.

    - Ashur

    Need more help? Ask us about Method consulting services

    Ashur Shamon
    Lead Solutions Specialist, Professional Services
    Method Integration Inc.
    www.method.me
    Toll Free: 1.888.925.6238
    Local and overseas: 416.847.0400
    Fax: 416.640.6027
    E-mail: a.shamon@method.me
Page 1 of 1 (7 items)