Code Monkey home page Code Monkey logo

Comments (4)

PaulNieuwelaar avatar PaulNieuwelaar commented on May 23, 2024

Hi Alex, looks like it's failing because the callback function is not being added correctly. You'll need to wrap it with function() { } like in the documentation example. As it is currently the refresh will occur before the dialog is displayed, which will likely mess up the alerts. Let me know if that works. Paul

from alertjs.

alex188888 avatar alex188888 commented on May 23, 2024

Hi @PaulNieuwelaar

Thanks for your replay.

I'm not sure I did it right (I'm new to JS and only studying) - Anyway, unfortunately it did not work :(

Alert.showDialogProcess ("62922E82-47FE-4100-9485-7D81370935B6", "phonecall", Xrm.Page.data.entity.getId(), function() { Xrm.Page.data.refresh (); }, 1200, 600)

from alertjs.

PaulNieuwelaar avatar PaulNieuwelaar commented on May 23, 2024

Hi Alex,

That looks correct now. However, looking at your ribbon workbench screenshot, you've got the function name as "alert.showDialogProcess", which doesn't look quite right. Is this the name of your function in your web resource? Can you show more context of your web resource, i.e. the function definition?

Ideally, the outer function should use your own namespace (not "alert"), or the function should just be something like "showDialogProcess" without the alert namespace. Then inside your custom function, you make the call to Alert.showDialogProcess as you've shown.

Hope that helps.
Paul

from alertjs.

PaulNieuwelaar avatar PaulNieuwelaar commented on May 23, 2024

Hi Alex,

Did you manage to solve this?

Cheers,
Paul

from alertjs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.