Skip to main content

Alert.js

Magnetism

4.8 (5)

Alert.js allows you to create custom lightbox popups in CRM, using custom buttons and messages.

Key Features:

  • Show confirmation messages to users
  • Capture input from users and process their responses
  • Display informative error messages
  • Fully customizable buttons and callback functions
  • Open custom HTML web resources inside a lightbox
  • Access web resource data from button callbacks
  • Show CRM dialog processes with custom callbacks
  • Display a loading spinner during async tasks

Overview:

CRM 2013 introduced light-boxes for most popups to make the UI look cleaner with less browser alerts and popups. However, these internal functions were not included in the SDK, so as developers we couldn't access them for our custom code. Instead, we've been forced to use alertDialog and confirmDialog which under the hood just calls the browsers alert and confirm functions. The main problems with this is that we cannot customize the buttons, and the alerts look ugly.

Using this library we can now create our own seamless alerts and popups using custom buttons and custom callback functions for each button. We can also specify different types of icons to display in the alerts, instead of being forced to use the alert 'exclamation mark' or confirm 'question mark'.

We can also use this technology to achieve more complex requirements, using the showIFrame and showWebResource functions to create our own custom popups.

https://store-images.s-microsoft.com/image/apps.30522.d2442ebe-3ce5-4290-af1d-4974f3b4dc02.3d01e979-c3d3-4eab-9baa-0a9e7ed568df.e93b948b-b236-4164-bb72-daf1d0753953
https://store-images.s-microsoft.com/image/apps.30522.d2442ebe-3ce5-4290-af1d-4974f3b4dc02.3d01e979-c3d3-4eab-9baa-0a9e7ed568df.e93b948b-b236-4164-bb72-daf1d0753953
https://store-images.s-microsoft.com/image/apps.43067.d2442ebe-3ce5-4290-af1d-4974f3b4dc02.3d01e979-c3d3-4eab-9baa-0a9e7ed568df.d3dfcc3c-e506-42d4-98bf-0203114e5ad9
https://store-images.s-microsoft.com/image/apps.54455.d2442ebe-3ce5-4290-af1d-4974f3b4dc02.3d01e979-c3d3-4eab-9baa-0a9e7ed568df.d7985f08-d440-43b7-afd9-af7b956e34d1