Set Status Bar Colour

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");
This entry was posted in SharePoint Shorts and tagged , . Bookmark the permalink.
0 0 votes
Article Rating
Subscribe
Notify of
guest

Solve the maths problem shown below before posting: *

0 Comments
Inline Feedbacks
View all comments