It is possible (and now supported) to show notifications on CRM forms, use the following code to show notifications.
Xrm.Page.ui.setFormNotification(<<Message>>, <<Level>>, <<uniqueId>>);
Xrm.Page.ui.setFormNotification(“Give some Info!”, “INFO”, “1”);
Xrm.Page.ui.setFormNotification(“Give a warning!”, “WARNING”, “2”);
Xrm.Page.ui.setFormNotification(“Give an error!”, “ERROR”, “3”);
The notifications will look like this ….
You can also remove a notification using the command below;
Xrm.Page.ui.clearFormNotification(“1”);
You can also set notification on a particular control.
Xrm.Page.getControl(“fieldname”).setNotification(“message”);
For example:
Xrm.Page.getControl(“department”).setNotification(“There is some kind of error with department!”);
Note: The form will not be saved until the notification is cleared!
Xrm.Page.getControl(“fieldname”).clearNotification();
Pingback: Happy New Year – Pop Pickers | Microsoft Dynamics CRM and Unified Service Desk