cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Button able to have multiple "Visible" criteria?

Hello All,

 

I have a created a Request app where users can obviously fill out a request and now I am creating a second app for the Managers to view those requests.... the Admin App. The Request app is connected to a SharePoint List and so is the Admin page so it can retrieve the records. I already have a gallery to where the managers can search for certain records and select the one they want and be navigated to the Details of that record using a Form that is connected to the selected record from the gallery. The form is initially in "View" mode, for obvious reasons, and just in case the manager needs to edit the record i created an "Edit" button that turns the From View to "Edit". I have also created a Button to Cancel the edit that is only visible when the Form View is in edit, so its not there when the view is in form, and will bring the Mode back to "View" . The code for the "Cancel" button is :

RequestDetailsForm.Mode = FormMode.Edit

 

The only problem is that I am also in a Tabbed View:

 

View Mode.PNG

 

So I need the "Cancel Edit" button to "Visible" for both only when the "Request Detail" Tab is selected:

RequestDetailsButton.DisplayMode = Disabled

 

AND for when The Form Mode is in Edit: 

RequestDetailsForm.Mode = FormMode.Edit

 

I have tried the code:

RequestDetailsForm.Mode = FormMode.Edit & RequestDetailsButton.DisplayMode = Disabled

 

But it does not work.

 

Any help is appreciated,

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
SeanHenderson
Impactful Individual
Impactful Individual

Set the visible on the cancel edit button to:

RequestDetailsForm.Mode = FormMode.Edit && RequestDetailsButton.DisplayMode = Disabled

 

---
Please hit the "Accept as Solution" button if my post answered your question! If my post was helpful please consider giving it a "Thumbs Up."

View solution in original post

2 REPLIES 2
SeanHenderson
Impactful Individual
Impactful Individual

Set the visible on the cancel edit button to:

RequestDetailsForm.Mode = FormMode.Edit && RequestDetailsButton.DisplayMode = Disabled

 

---
Please hit the "Accept as Solution" button if my post answered your question! If my post was helpful please consider giving it a "Thumbs Up."

View solution in original post

Anonymous
Not applicable

Worked Like a charm!! Thanks a lot!

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,220)