cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
davidyc
Helper I
Helper I

Model Driven App Dashboard: Specify default form to be used when opening record from view on a dashboard

Hi there,

 

I have a dashboard in my Model Driven App with a series of 6 views all based on the Contact entity. When a user clicks on a record from any of the views, I would like a specific form to be shown by default, rather than one of the other main forms on the Contact entity.

 

Unfortunately defining a form order won't be an answer since I need to explicitly specify another default form on the same entity in another context. 

 

Can anyone advise if there is a way to meet this requirement?

 

model-driven apps

model driven

1 ACCEPTED SOLUTION

Accepted Solutions
GarethPrisk
Resident Rockstar
Resident Rockstar

You can technically use the DOM, and other methods, to effectively run your own function on the views in the dashboard. However, I don't recommend this because users can/will get to Contacts from other places (non-dashboard), and then the behavior will not exist.

 

An alternative approach would be to use JavaScript on the form(s). This is a bit heavy-handed, but can work.

  • Presumably the views on the dashboard are based on parameters
  • You could use those same parameters (IF {Contact Field} = A, THEN X, ELSE IF {Contact Field} = B, THEN Y, ELSE Z)
  • You could determine the form the user is on, and if it's not the correct form you could redirect them
  • I don't love this because it effectively will double-navigate a user and may be jarring

An additional alternative approach would be to consolidate the forms into a single form. Then dynamically show/hide elements that are specific to the Contact that has been selected.

View solution in original post

4 REPLIES 4
GarethPrisk
Resident Rockstar
Resident Rockstar

Change the form order, to ensure it is considered the default form for the user.

https://docs.microsoft.com/en-us/powerapps/maker/model-driven-apps/assign-form-order

Additionally, if a user switches forms, it should cache that selection and continue to use the form.

Thanks Gareth, my understanding is that the form order can only be controlled at the entity level - is that correct? I want to specify a default form for one view on the Contact entity and another form for a different view on the contact entity - can this be done? 

GarethPrisk
Resident Rockstar
Resident Rockstar

You can technically use the DOM, and other methods, to effectively run your own function on the views in the dashboard. However, I don't recommend this because users can/will get to Contacts from other places (non-dashboard), and then the behavior will not exist.

 

An alternative approach would be to use JavaScript on the form(s). This is a bit heavy-handed, but can work.

  • Presumably the views on the dashboard are based on parameters
  • You could use those same parameters (IF {Contact Field} = A, THEN X, ELSE IF {Contact Field} = B, THEN Y, ELSE Z)
  • You could determine the form the user is on, and if it's not the correct form you could redirect them
  • I don't love this because it effectively will double-navigate a user and may be jarring

An additional alternative approach would be to consolidate the forms into a single form. Then dynamically show/hide elements that are specific to the Contact that has been selected.

View solution in original post

Thank you Gareth! i think the last idea is favourable in this instance I will mark as the solution.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (1,121)