Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Microsoft Dataverse
Unanswered

Button not hidden on closing custom page in model driven app

(0) ShareShare
ReportReport
Posted on by 2

Hi all,

We have an issue with a model driven app. This app contains a dialog that is implemented as a custom page. The custom page is opened from a main form in the app via a button that is added via the command designer:

  • The action on the command is a java script that opens the custom page: 

 

 Xrm.Navigation.navigateTo(pageInput, navigationOptions)
 .then(
 function success() {
 // Called when the dialog closes
 formContext.data.refresh();
 formContext.ui.refreshRibbon();
 },
 function error() {
 console.log("An error occurred");
 }
 ).catch(
 function (error) {
 console.log("An error occurred");
 }
 );

 

  • The visibility property of the command is set based on a formula that shows the button based on the status of the record (something like Self.Selected.Item.Status = 'My status'.Open

 

When the custom page is closed, the record that was shown on the main form in the model driven app is patched and the status of the record is changed to 'Closed'.

 

The solution that contains this app also includes a custom role. Now the issue is that if a user has this custom role, the button in the main form on the model driven app is not hidden after the custom page is closed (so status of the record changed to 'Closed').

When executing this logic as System Administrator, the button is hidden as expected.

 

Any thoughts on why this is not functioning as expected for users that only have this specific custom role?

Is this some security issue and if so what permissiong could be missing on the role?

Is there an easy way to find out why his is not working as expected for users with the custom role only?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Leaderboard > Power Apps - Microsoft Dataverse

#1
mmbr1606 Profile Picture

mmbr1606 22 Super User 2025 Season 1

#2
stampcoin Profile Picture

stampcoin 19

#3
Michael E. Gernaey Profile Picture

Michael E. Gernaey 15 Super User 2025 Season 1

Overall leaderboard

Featured topics