Overview
With buttons, you have the ability to disable them until specific conditions are met. In this example, we will disable a button until all fields are entered before a record can be created.
YouTube
Button Defaults
By default a button will have it’s display mode as DisplayMode.Edit

As you can see there are no conditions, so this button can always be selected. Here is the DisplayMode property

If the display mode is changed to DisplayMode.Disabled, the button will not trigger the OnSelect property. Here is what a disabled button look like

Conditionally Disabling Button
In this scenario, we will only allow the button to be active if the following conditions are met:
- Subject is not blank
- Due Date is not blank
- Radio button has option selected
- Description is 10 or more characters

With the following code, we can accomplish this
If(IsBlank(text_Subject.Text) || IsBlank(date_DueDate.SelectedDate) || IsBlank(radio_Owner.Selected) || Len(text_Description.Text) < 10,
DisplayMode.Disabled,
DisplayMode.Edit
)
In the If statement, any condition could be met and the button will be disabled. This is why we are using the double pipes || for an Or condition. If none of the conditions are met, then the button will be abled

Example of button disabled with one condition met (subject being blank)

Example where no conditions were met, so button is enabled

