Purpose
A Power Apps button control is used to trigger an action when clicked or tapped. Its purpose is to provide a way for the user to initiate actions and navigate through an interface.
Properties
AcceptsFocus Determines whether the button can be focused on using the tab key or SetFocus function |
AccessibleLabel Screen readers will voice this text when a user selects the control |
Appearance Sets the button’s style Options: = “Primary” = “Secondary” |
ContentLanguage Describes the language used to the audience (e.g. “en-US”) |
DisplayMode Selects the mode: Edit, View or Disabled. In Edit mode the user can input values. In View mode the user can only see the values and in Disabled mode the control is greyed-out. Options: = DisplayMode.Disabled = DisplayMode.Edit = DisplayMode.View |
Height Distance from the top of the control to the bottom |
OnChange Unknown purpose. |
OnSelect Actions that will be executed when the button is pressed. |
Text Text displayed on the button |
Visible Determines whether to show or hide the control |
Width Distance from the left side of the control to the right side |
X Distance from the left edge of the screen to the left side of the control |
Y Distance from the top edge of the screen to the top of the control |
How To Use The Power Apps Button Control
1. Select the button control in Power Apps studio. Input a value into the Text property.
"OK"
2. Write code in the OnSelect property of the button to execute an action when the button is pressed.
Set(varShowMenu, false);
3. Click on the button to run the action.
Did You Enjoy This Article? 😺
Subscribe to get new Power Apps articles sent to your inbox each week for FREE
Questions?
If you have any questions or feedback about Power Apps Button – Modern Controls please leave a message in the comments section below. You can post using your email address and are not required to create an account to join the discussion.
I like the new features, but this one in particular confuses me. How is this different from any other button?
The imagery is better, but otherwise…
John,
The official blog’s article says these controls will eventually have their styling controlled by a built-in theming system. So that’s a major win. And I like how you can switch between Primary and Secondary button theming easily. Other than that, it’s the same.
I’m using the modern form and controls and seeking assistance with the unsaved function. In the legacy form, I successfully used this function to disable the button when there were no changes in the form. However, I’m encountering challenges adapting it to work with the modern controls. Any guidance or suggestions would be greatly appreciated.
If(FormName.Unsaved, DisplayMode.Edit,DisplayMode.Disabled)
Mohammed,
I’m having the same kind of problem. I’ve tried both classic and modern buttons, and I’m not having any success changing the display mode from within a button’s own click or through another event, like the screen OnVisible or another button click. I’d love some help here, too.
The tooltip is now longer available for the modern controls? Understand, we can do a workaround with that using an icon but this would add up to the count of the number for controls when I have a complex screen/app with 200+controls..
I am having the same issue, The text label no longer has onSelect Property, Buttons no longer has tooltips, I don’t know if we are going ahead with modern controls or getting stuck with changes in the applications with errors and unavailability of properties that were earlier present.
Hi, my action button is missing from the top bar..i want to navigate my button to other page. How do i solve this?