Hi Community,
Xrm.Dialog in the Javascripts doesn't seems to be working in UCI. Can someone help me out with any replacements for this.
Thank You!
Hi Community,
Xrm.Dialog in the Javascripts doesn't seems to be working in UCI. Can someone help me out with any replacements for this.
Thank You!
Can you share an example?
docs.microsoft.com/.../navigateto
Here is a code sample from the docs page, in that first collection you would have to add 'data' object which sounds like what you are doing and you are not able to retrieve this value in the web resource?:
var pageInput = {
pageType: "webresource",
webresourceName: "new_sample_webresource"
};
var navigationOptions = {
target: 2,
width: 400,
height: 300,
position: 1
};
Xrm.Navigation.navigateTo(pageInput, navigationOptions).then(
function success() {
// Handle dialog closed
},
function error() {
// Handle errors
}
);
Hello Nikita polyakov,
I'm using Xrm.Navigation.navigateTo(pageInput, navigationOptions) to navigate to the html. Here I'm passing a string value through data in pageinput object. My doubt is how can I get that value in html code.
Thank You!
Hi,
This looks like what you are looking for.
var displayMessage = "Are you sure you want to do something here?"; var confirmStrings = { text: displayMessage, title: "What are you doing" }; var confirmOptions = { height: 80, width: 260 }; Xrm.Navigation.openConfirmDialog(confirmStrings, confirmOptions).then( function (success) { if (!success.confirmed) { //Set the field back to false formContext.getAttribute("new_issetupcompleted").setValue(false); return; } //Do something } );
Please look at this if this fits your needs:
docs.microsoft.com/.../navigateto
Specifically this works well with web resources that need to be visualized in "Modal Dialog" way:
navigationOptions
target: Number. Specify 1 to open the page inline; >>>>> 2 to open the page in a dialog. <<<<<
Entity lists can only be opened inline; >>>>>> web resources can be opened either inline or in a dialog. <<<<<<
Hello,
What is that script doing exactly?
If you need to display a message to a user with OK & Cancel buttons, then you should consider using this method:
https://docs.microsoft.com/en-us/powerapps/developer/model-driven-apps/clientapi/reference/xrm-navigation/openconfirmdialog
Henry
Hi Henry,
Below is the Snippet code in the javascript.
var DialogOption = new Xrm.DialogOptions;
DialogOption.width = width; DialogOption.height = height;
// DialogOption.width = 1200; DialogOption.height = 620;
Xrm.Internal.openDialog(src,
DialogOption,
null, null,
CallbackFunction);
Do we have any replacement for this.
Thank You,
S. Giridhar Raju
Are you also using namespaces such as Xrm.Internal.openDialog in your code?
Because using Xrm.Internal clearly shows that this is not supported and this is probably why it doesn't work in Unified Interface.
Can you please share more details on your code and what exactly you're trying to achieve with this script?
Thanks
Henry
Hi Henry,
var DialogOption = new Xrm.DialogOptions;
This is where I find the error
Thank!
Hello,
Can you share more details about your use of Xrm.Dialog?
I don't thing this has ever been a documented and supported Client API.
Or are you talking about Process Dialogs? They indeed no longer work in Unified Interface, as announced here:
https://docs.microsoft.com/en-us/power-platform/important-changes-coming#process-dialogs-are-deprecated
Henry
André Arnaud de Cal... 291,820 Super User 2024 Season 2
Martin Dráb 230,514 Most Valuable Professional
nmaenpaa 101,156