SharePoint Short #1
To set the colour of a SharePoint 2010 status message, it’s important to specify it in lower-case and not start with an upper-case letter.
The MSDN page for setStatusPriColor, found here, shows the colour values starting with an upper-case letter.
So, instead of:
this.statusId = SP.UI.Status.addStatus("Custom error message", true); SP.UI.Status.setStatusPriColor(this.statusId, "Red"); |
you need to do:
this.statusId = SP.UI.Status.addStatus("Custom error message", true); SP.UI.Status.setStatusPriColor(this.statusId, "red"); |