Announcements
Hi,
We have an EmailTemplate entity with custom control set as its default control.
The Email Templates page opens with the records presented in the custom control, as expected. User gets an option on the toolbar to swap to the Read-Only version (see below).
However I need to include a button in the custom control to swap to the Read Only Grid on click.
Inside the Thumbnails PCF component I need to navigate to the other view Read-only Grid (default) when a user clicks a button in the iFrame. I'm not concerned with how the iFrame and PCF component communicate as that is already in place. I am unsure though how to navigate and avoid opening the entitylist in the default control i.e. the thumbnails control
I am new to this but reckon I need to call Navigation.navigateTo() as below but do not know how to specify the non-default control i.e. the Read Only Grid.
var pageInput = { pageType: "entitylist", entityName: "emailtemplates" }; // What value should I use for pageType?
Xrm.Navigation.navigateTo(pageInput).then( function success() { // Run code on success }, function error() { // Handle errors } );
Perhaps that is not the correct approach but I have spent the day reading documentation and can't figure it out.
I would appreciate any help.
Seamus
Thanks for your input Steve.
Hi sbarrett,
I haven't any way to achieve your requirement.(I kind of doubt whether this requirement can be fulfilled)
However, I don't think navigateTo() method can do this. The value of pageType is listed in the Doc(https://docs.microsoft.com/en-us/powerapps/developer/model-driven-apps/clientapi/reference/xrm-navigation/navigateto) and none of them can be used to change the control. There is a parameter named pageType in the URL, when you change the control, it couldn't be changed. And there is no other parameter in this method can do this, so I think this method could not help you.
I recommend you open a ticket to get further help from Microsoft.
André Arnaud de Cal... 291,359 Super User 2024 Season 2
Martin Dráb 230,370 Most Valuable Professional
nmaenpaa 101,156