Forum Migration Notice
We're transitioning to a more modern community platform by the end of this year. Learn about the upcoming changes and what to expect.

checkbox in appstudio

i want to use a checkbox in appstudio but i can not found how to bind it with a bool in rapid code. greetings

Answers

  • I created a function in a class that checks whether a component should be active or not. You can change this to require a signal and then do the following:

    updateUiIcon() {
        const active = this.isActive();
        this.component.icon = active
            ? "abb-icon abb-icon-abb_check-mark_16"
            : null;
      }

    isActive() {
        return this.component.toggle === 1;
      }