Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Microsoft Dataverse
Unanswered

Closing Popup form opened from subgrid

(0) ShareShare
ReportReport
Posted on by 274

Use case: Our users are going to need to answer questions from a subgrid and therefore need a means to work through the questions without having to scroll back to their starting point.  The idea is use a popup form for the Inspection Questions and when the question is answered or closed they are still at the same position on the Assessment subgrid.  Ideally, the colors used for the scores would show up on the subgrid, when refreshed.

Question: Is there a JavaScript that can open a popup form w/in a model driven app, using a Power App grid control?

Research: Clicking on a Subgrid to Open a Modal Form in Dynamics 365 - Carl de Souza

Testing with a Power App grid control, which shows the colors from my choices, fails to execute the JavaScript code below.  The code works when I use an Editable grid (as recommended in the video).

 

function RunOnSelected(executionContext) {
var selected = executionContext.getFormContext().data.entity;
var Id = selected.getId();
 
var pageInput = {
pageType: "entityrecord",
entityName: "contact",
entityId: Id
};
var navigationOptions = {
target: 2,
height: {value: 50, unit:"%"},
width: {value: 50, unit:"%"},
position: 1
};
Xrm.Navigation.navigateTo(pageInput, navigationOptions).then(
function success() {},
function error() {}
);
}

 

Visual that the JavaScript is on and works from using the editable grid.  Visually, I'd like to get the choice colors to show up and I only know how to do that we a "power app grid control" but then the popup script doesn't work.

damian_green23_0-1709604338306.png

 

Categories:
  • damian_green23 Profile Picture
    274 on at
    Re: Closing Popup form opened from subgrid

    That works for a canvas app.  What about a model driven one?

  • Rahman1005 Profile Picture
    109 on at
    Re: Closing Popup form opened from subgrid

    Hi,

    Could you please refer below bog.

    https://crmnewlearning.blogspot.com/2022/05/open-canvas-app-with-customize-command.html

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 17

#3
Michael E. Gernaey Profile Picture

Michael E. Gernaey 15 Super User 2025 Season 1

Overall leaderboard

Featured topics