Blog
Dataverse - How to set yes no values with checkbox- Walkthrough
This post walks through how to set a Dataverse yes/no field with a checkbox rather than a dropdown.
This post walks through an example of how to set Dataverse yes/no fields with a checkbox.
Setting up an example app and form
For this example, let's take a table called 'Project' with a yes/no field named 'IsUrgent'.
From the Apps section of the Power Apps portal, we'll select the 'Start with data' option to create an app based on the Project table.
The generated app uses a combo box in the form to display the IsUrgent field; there is no way to select a checkbox.
Here are the steps to convert the combobox to checkbox.
Step 1 - Replace the combobox with a checkbox
From the designer, unlock the card and delete the combobox control.
Insert a checkbox control called chkIsUrgent
There will be 2 errors in the form related to the missing combobox control. For the Y property of the Error Message label (shown below), we can replace the reference to DataCardValue4 (the deleted combobox control) with chkIsUrgent.
chkIsUrgent.Y + chkIsUrgent.HeightCode
Step 2 - Configure the Update property of the card
If(chkIsUrgent.Value = true,
'IsUrgent (Projects)'.Yes,
'IsUrgent (Projects)'.No
)

If you were re-creating this example for a different table, you would need to use this syntax to represent yes and no values
- 'YesNoFieldName (TableName)'.Yes
- 'YesNoFieldName (TableName)'.No
Step 3 - Configure the Default property of the checkbox
If (ThisItem.IsUrgent = 'IsUrgent (Projects)'.Yes, true, false)

At this point, we can run our app and use the checkbox to set the yes/no field.
Conclusion
Setting a Dataverse yes/no field with a checkbox isn't straightforward. This post walked though an example of how to convert a combobox on a form to a checkbox.
- Categories:
- Dataverse
- Dataverse - Add image column missing when creating table - how to fix
- Data - How to view the progress and status of a Dataverse CSV/Excel Import
- Error - Diagnosing the error "Network error when using the Patch function" when saving data with a form
- Dataverse - How to work around the error "multiple levels of many-to-one relationship expansion aren't supported"
- Dataverse - The easiest way to modify Dataverse data outside of Dataverse and Power Apps
- Dataverse - How to use a checkbox control a set a yes/no field in Dataverse
- Dataverse - How to create Entity Relationship diagrams
- Dataverse - How you can more quickly bulk update data using the SQL language
- Dataverse - How to fix the bug in the 'Business Rules' editor that prevents numeric values from saving
- Dataverse - What are the benefits, and how to create formula columns
- Dataverse - How to sort the available choice items from a choice column
- Error - Unable to modify Dataverse tables with error message, Language id should not be null
- Dataverse - How to retrieve FetchXML or SQL for Dataverse views
- Data - Why is Dataverse so fast?
- Dataverse - How to create and use Dataverse views in Canvas Apps
- Dataverse - How to filter Dataverse choice columns
- Dataverse - How to switch to the classic designer when the option is not available
- Licensing - What are Dataverse Restricted tables?
- Media - How to save and work with microphone recordings
- Dataverse - how to access tables from another environment
- Dataverse - How to Patch the 5 most complex data types