Sep 03 2023 05:54 PM
Sep 03 2023 05:54 PM
Hi, I am very new to form building and not very technical so please bear with me.
I am trying to get a field to only be visible when the toggle button is turned on.
How would I go about achieving this?
Sep 04 2023 02:55 AM
@Vdraper you will need to use a customized form with Power Apps for this.
1. In your SharePoint list click Integrate then Power Apps then Customize forms:
2. Power Apps will open with your form displayed. On the Insert menu select Toggle:
3. The toggle will be added. In the simple example below I've made the Department datacard bigger and dragged the toggle into an appropriate position. From the Advanced tab on the format panel I've also changed the False Text and True Text:
4. Select the field you want to make hidden or visible dependiing on the toggle value. In the property field at the top left above Tree View select Visible from the dropdown and in the formula field type If(Toggle1.Value=true,true,false)
Save and p[ublish your form back to SharePoint from the icons in the very top right of Power Apps and then go back to the list. If you make changes to your form you will probably find you need to refresh your screen several times to see the changes due to the caching that goes on. But when you open an item in the list, when you click the toggle the (in this case) the department field will be displayed; click the toggle again and it will be hidden.
Microsoft Power Automate Community Super User.
Intranet, SharePoint and Power Platform Manager (and classic 1967 Morris Traveller driver)
Sep 04 2023 04:46 AM
@Vdraper You can also achieve this using SharePoint out of the box capabilities (without using Power Apps forms). Follow below steps:
Where YesNoColumnInternalName is the internal name of your Yes/No column. You can get the internal name of your columns by following this article: How to find the Internal name of columns in SharePoint Online?
Follow this Microsoft official documentation for steps showing where to add the conditional formulas: Show or hide columns in a SharePoint list or library form
Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.