Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Confused with these commands, as I heard these are deprecated...

Posted on by 108

Hi All,

I heard the below commands are deprecated in MS CRM. If deprecated please help me with the information on updated commands in-place of these...

 1. Mscrm.InlineEditUtilities.tryResetFocusOnActiveControl();

2. Mscrm.InternalUtilities._Script.alert

3. Xrm.Internal.getResourceString

4. Mscrm.InlineEditUtilities

Thank You,

GSK.

*This post is locked for comments

  • Suggested answer
    Javed Iqbal Profile Picture
    Javed Iqbal 85 on at
    RE: Confused with these commands, as I heard these are deprecated...

    You can use this for 8.1, 8.2.. u might need to add jquery on the form.

    function loading() {
    var loadingDiv = "<div id='divLoading'style='width: 100%; height: 100%; display: block; position: fixed; top:0px; background:rgba(255,255,255,0.5);'><table style='width: 100%; height: 100%;'><tr><td align='center' style='vertical-align: middle;'>";
    loadingDiv += "<img id='loading' alt='' src='..//WebResources/val_progressbar'/><br/>";
    loadingDiv += "<label id='lblStatus'>Processing.....</label>";
    loadingDiv += "</td></tr></table></div>";
    $($('body', window.parent.document)).append(loadingDiv);

    }
    function CloseDialog() {
    $($('body', window.parent.document)).find("#divLoading").remove();
    }

  • Suggested answer
    Syed Ibrahim Profile Picture
    Syed Ibrahim 6,257 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Alternatively you can use sweetalert JS to achieve this

    Code for alert:

    swal({

     title: "Background Process Ongoing!",

     text: "I will close in 2 seconds.",

     timer: 2000,

     showConfirmButton: false

    });

    Reference Link: sweetalert.js.org/docs

  • SaiKrishnaGudluru Profile Picture
    SaiKrishnaGudluru 108 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Hi Ravi, we are looking for CRM in-built commands.

  • SaiKrishnaGudluru Profile Picture
    SaiKrishnaGudluru 108 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Thank You Aric for the information. I have tried shoeprogressindicator, but seems it supports from V9 and above. But I am looking for this to work in D 365 8.1 and 8.2 (since most of applications are currently D 365 8.1 and 8.2 we are working). Any Suggestions or Workaround on this? - main motto is to use in-built CRM commands.

  • Suggested answer
    Syed Ibrahim Profile Picture
    Syed Ibrahim 6,257 on at
    RE: Confused with these commands, as I heard these are deprecated...

    There is cool feature to make user to wait upon some time take operation in the background by showing custom message on progress bar.

    Call the below js upon the event triggered.

    function ShowCustomMsg() { Xrm.Utility.showProgressIndicator("Loading contact email.."); setTimeout(delayedLoadPrimaryContact, 10000); }

    For more detail. Pls refer below link.

    community.dynamics.com/.../dynamics-365-v9-progress-indicator-api

    Hope this will solve your problem.

  • Suggested answer
    Aric Levin Profile Picture
    Aric Levin 30,188 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Since you are worried about the deprecation of commands, the July 2017 Update (where the deprecation was announced), contains the method Xrm.Utility.showProgressIndicator, which is somewhat the replacement of Xrm.Internal.Progress that you are using.

    Deprecation of commands is not immediate. That means that it is still working in the July 2017 Update, and will give you some time to fix your code before moving to the next release.

    Although, you should not have used the Internal methods, I would say that since they are working, leave them until you are moving to the next release where you can use the OOB showProgressIndicator as mentioned.

    See link here:

    docs.microsoft.com/.../showprogressindicator

    Hope this helps.

  • Suggested answer
    RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Hi,

    You can try alert.js library.

    github.com/.../Documentation

    Hope this helps.

  • SaiKrishnaGudluru Profile Picture
    SaiKrishnaGudluru 108 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Hi Ravi, thank you for the prompt response. Seems, we don't require the above mentioned commands. Even after removing those commands also our functionality is working as expected. But issue is Xrm.Internal.Progress we are using and looking for an updated command for this. Basically we are converting an email to case with a custom web resource and trying to show the progress with this

  • Mahendar Pal Profile Picture
    Mahendar Pal 45,095 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Agree with Ravi,

    You were already using unsupported commands, sharing requirement here can be help to get suggestion to implement in supported way.

    Thanks

  • Suggested answer
    RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: Confused with these commands, as I heard these are deprecated...

    Hi,

    I don't think these were ever supported. These are intermal method and should not be used.

    For 'Mscrm.InternalUtilities._Script.alert' it looks like you used this to show alert. For this you can use, Xrm.Utility.alertDialog(message,onCloseCallback)

    msdn.microsoft.com/.../jj602956.aspx

    For other commands, please share the logic/ scenario where you have used these commands.

    I hope this helps.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans