Power Apps Checkbox Value

Do you how to set a Power Apps checkbox value? Follow this Power Apps tutorial to get all the information about the Power Apps checkbox value.

Here, we will discuss what are the properties of a Power Apps checkbox control. Also, we will see how to add a checkbox control and Power Apps checkbox value manually.

Additionally, we will also cover the below topics. Such as:

  1. How to set Power Apps Checkbox Value from SharePoint List
  2. PowerApps if Checkbox is Checked
  3. Power Apps Checkbox Checked Value

Power Apps Checkbox

The Power Apps Checkbox control allows the user to select or clear to set its value to true or false and this control allows users to select one or multiple options from a list of choices.

When a user selects the Power Apps check box, the value will be true and when it is cleared, then the value will be false.

PowerApps checkbox Properties

Here, we will see what are the key properties of the checkbox control in the Power Apps.

Refer to the below table:

PropertyDescription
TextIt specifies the text that appears on the control or you need to type a text into the control
ValueThis Value property specifies the value of the input control
DefaultIt is the initial value of control before it is changed by the user
BorderColor  It helps to display the color of a control’s border
OnCheckIt specifies how an app responds when the value of a checkbox or a toggle changes to true
OnSelectIt specifies how the app responds when the user taps or clicks a control
OnUncheckIt specifies how an app responds when the value of a checkbox or a toggle changes to false
ResetIt specifies whether the control reverts to its default value
Size It helps to set the font size of the text that appears on a control
VisibleIt specifies whether a control appears or hidden
CheckmarkFill It defines the color of the checkmark in a checkbox control
Color It defines the color of the text in a control
FillIt specifies the background color of a control
VisibleIt specifies the text appearing on the control, or you need to type it into the control

These are the properties of a Power Apps checkbox control.

See also  Power Apps Len Function | Power Apps Length Of String

How to Add Power Apps Checkbox Control

Next, we will see how to add a Power Apps checkbox control to a Power Apps canvas app.

1. Open Power Apps with your respective Microsoft credentials -> Create a Blank canvas app as shown below.

powerapps checkbox value

2. On the Power Apps Screen -> Insert a Check box control [Click on the + Insert button -> Expand Input -> Select Check box].

3. By default, the Checkbox’s Text property is “Option” and the name of the Checkbox is CheckBox1 as in the screenshot below.

powerapps checkbox

This is how to add a Power Apps checkbox control in a canvas app.

How to Set Power Apps Checkbox Value

Let’s see how to set the Power Apps checkbox value using two examples. Such as:

  1. Power Apps Checkbox Value Manually
  2. How to set Power Apps Checkbox Value from SharePoint List

Power Apps Checkbox Value Manually

In Power Apps, there is a checkbox control, and this control contains the below manual value, i.e., [Check Now].

Refer to the below screenshot:

checkbox in powerapps

To do so, select the Checkbox control and set its Text property to the code below.

Text = "Check Now"

This is how to set the Power Apps checkbox value.

Set Power Apps Checkbox Value from SharePoint List

Here, we will see how to set a PowerApps checkbox value from the SharePoint list with a simple scenario:

Scenario:

I have a SharePoint list Online named “Product Details”. This list contains the below fields.

Set Power Apps Checkbox Value from a SharePoint List

In Power Apps, there is a Checkbox control, a gallery control, and a Text input control. When the user selects any product name from the checkbox control inside the gallery, the Text input control displays the selected product price as in the screenshot below.

Set Power Apps Checkbox Value from SharePoint List

To achieve it, follow the below steps. Such as:

See also  Power Apps Filter Gallery by Dropdown [With Examples]

1. On the Power Apps screen -> Insert a Blank flexible gallery control and set its Items property as:

Items = 'Product Details'

Where,

  • ‘Product Details’ = SharePoint Online List
How to Set the Power Apps Checkbox Value from SharePoint List

2. Then, insert a Checkbox control inside the gallery and set its Text property to the code below.

Text = ThisItem.Title

Where,

  • Title = SharePoint list text field
Set Power Apps Checkbox Value from SharePoint Online List

3. Whenever we add a Check box control, we can select multiple check box values. However, our requirement is only to select a single check box value instead of multiple selections.

How to Set a Power Apps Checkbox Value from the SharePoint List

4. To do so, set the Check box’s OnCheckDefault, and DisplayMode properties as shown below.

OnCheck = Set(
    varCheck,                                                                             //OnCheck Property
    gal_EmployeeDepartments.Selected.Title
)

Default = varCheck=ThisItem.Title                              //Default Property

DisplayMode = If(
    varCheck = ThisItem.Title,                                           //DisplayMode Property
    DisplayMode.View,
    DisplayMode.Edit
)

Where,

  • varCheck = Power Apps Variable Name
  • gal_EmployeeDepartments = Power Apps Gallery Name
Set a Power Apps Checkbox Value from SharePoint List

5. In the last, insert a Text input control and set its Default property to the code below.

Default = LookUp(
    'Product Details',
    Title = chk_Departments.Text
).Price

Where,

  • LookUp() = This function uses LookUp to find a single record that matches one or more criteria
  • ‘Product Details’ = SharePoint Online List
  • chk_Departments = Power Apps Checkbox Name
  • Price = SharePoint list Currency Column
How to Set Power Apps Checkbox Value from SharePoint List

6. Save, Publish, and Privew the app. Whenever the user selects any product name from the checkbox control inside the gallery, the Text input control displays the selected product price as in the screenshot below.

How to Set a Power Apps Checkbox Value from SharePoint List

This is how to set a PowerApps checkbox value from the SharePoint list.

Power Apps If the Checkbox is Checked

In this section, I will explain the Power Apps if the checkbox is checked with a simple scenario:

Scenario:

In Power Apps, there is a Checkbox control, a Button control, and a Text label. Whenever the user clicks on the button control, the text label will display the text, i.e., [Check is Checked or Check box is Not Checked] based on the check box selection [If checked or not].

Refer to the below screenshot:

power apps if checkbox is checked

To do so, follow the below steps.

See also  How to Work With Power Apps PDF Viewer Control [With Examples]

1. On the Power Apps Screen -> Insert a Checkbox control and set its Text property to the code below.

Text = "Terms and Conditions"
powerapps if checkbox is checked

2. Then, insert a Button control and set its OnSelect property to the code below.

OnSelect = Set(
    varChecked,
    If(
        chk_Selected.Value = true,
        "Check Box is Checked",
        chk_Selected.Value = false,
        "Check Box is Not Checked"
    )
)

Where,

  • varChecked = Power Apps Global Variable Name
  • If() = The Power Apps IF() Function performs a logical comparison to see if the result is true
  • chk_Selected = Power Apps Checkbox name
powerapps if check box is checked

3. Next, insert a Text label and set its Text property as:

Text = varChecked
power apps if check box is checked

4. Once your app is ready, Save, Publish, and Preview the app. When the user clicks on the button control, the text label will appear with text based on the checkbox selection [If Checked or Not] as in the screenshot below.

If PowerApps check box is checked

This is all about the Power Apps if the checkbox is checked.

Power Apps Checkbox Checked Value

In the last, we will see the Power Apps checkbox checked value with a simple example:

Example:

I will also take the above SharePoint Online List [Product Details] for this example. In Power Apps, there is a Gallery control having the SharePoint list “Title records”, a Button control, and a Text label.

Whenever the user selects a check box value or values and clicks on the button control, the text label will display checkbox checked values as in the screenshot below.

powerapps checkbox checked value

To do so, follow the below steps. Such as:

1. On the Power Apps Screen -> Insert a Gallery control and set its Items property as:

Items = 'Product Details'

Where,

  • ‘Product Details’ = SharePoint Online List

2. Then, insert a Checkbox control inside the gallery and set its Text property to the code below.

Text = ThisItem.Title
power apps checkbox checked value

3. Then, insert a Button control and set Its OnSelect property to the code below.

OnSelect = Set(
    varCheckedItems,
    Concat(
        Filter(
            gal_Products.AllItems,
            chk_ProductNames.Value
        ),
        Title & ","
    )
)

Where,

  • varCheckedItems = Power Apps Global Variable Name
  • gal_Products = Gallery Control Name
  • chk_ProductNames = Check Box Name
  • Title = SharePoint List Text Field
powerapps check box checked value

4. Next, insert a Text label and set its Text property as:

Text = varCheckedItems
power apps check box checked value

5. Save, Publish, and Preview the app. When the user selects a check box value or values and clicks on the button control, the text label will display checkbox checked values like below.

powerapps checkbox control checked value

This is all about the Power Apps checkbox checked value.

Conclusion

From this Power Apps tutorial, we learned all about the Power Apps checkbox value. Here, we discussed what the Power Apps Checkbox control is and what are the properties of a Power Apps checkbox control.

Then, we saw how to add a checkbox control in the Power Apps and Power Apps checkbox value manually.

Moreover, we also covered the below topics. Such as:

  1. How to set Power Apps Checkbox Value from SharePoint List
  2. PowerApps if Checkbox is Checked
  3. Power Apps Checkbox Checked Value

You may also:

  • Hi Bijay, I have yes/No column on sharepoint column and I want to use check and uncheck on poweApps but it is not working do you have some idea, when we add yes on sharepoint the powapps by default checked unless unchecked

  • Hi Bijay, Good knowledge. I am a new PowerApper and would like to have your help. I have Choices column with multiple selections. I would like to populate the value in Checkbox control within Gallery control. There are 9 choices for that column. If my sharepoint list record has only 3 values, how can we display those 3 choices checked while the other 6 check boxes unchecked. Thanks.

  • >