🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Core2 checkbox set_checked doesn't work

    Scheduled Pinned Locked Moved General
    4 Posts 3 Posters 7.3k Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M Offline
      mwenghi
      last edited by

      Hello everyone,

      I'am using UiFlow Beta V1.7.1 with Core2 (v1.7.1-core2 firmware). The block Set checkbox checked seems doesn't really work after running on the device, checkbox remain unchecked.

      0_1609988337865_Screen Shot 2021-01-07 at 3.50.41 AM.png

      When I use set_checked for toggling two checkboxes, it seems to work only sometimes.

      0_1609990536942_Screen Shot 2021-01-07 at 4.23.21 AM.png

      V 1 Reply Last reply Reply Quote 0
      • felmueF Offline
        felmue
        last edited by

        Hello @mwenghi

        I can confirm that set_checked doesn't work with UIFlow 1.7.1.1 firmware. I can change the text of a checkbox with set_text, but changing the state of the checkbox doesn't work.

        Thanks
        Felix

        GPIO translation table M5Stack / M5Core2
        Information about various M5Stack products.
        Code examples

        1 Reply Last reply Reply Quote 0
        • V Offline
          veryalien @mwenghi
          last edited by

          @mwenghi I've worked out that set_checked does actually work. It changes the internal state of the checkbox from unchecked to checked, but it's not changing the visible state of the checkbox on the screen, so it doesn't appear to do anything!

          If you add a set_checked_color call (in blockly it's the block set selectedColor) after your set_checked it will then show the relevant checkbox as checked in your desired color.

          1 Reply Last reply Reply Quote 1
          • felmueF Offline
            felmue
            last edited by

            Hello @veryalien

            nice work-a-round. Hopefully it will be fixed soon though.

            Thanks
            Felix

            GPIO translation table M5Stack / M5Core2
            Information about various M5Stack products.
            Code examples

            1 Reply Last reply Reply Quote 0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            • First post
              Last post