Representing risks in a matrix or heat map type view is pretty common so lets take a look at how we can do that in SharePoint.
First of all we need to capture our risks in a list
- Create a new custom list and rename the default Title column to Risk to capture a label for our risk
- Create a new Choice field called Consequence and use the following options:
- Create a new Choice field called Likelihood and use the following options:
- Almost Certain
- Create a new Calculated column called ConsequenceScore and use this formula:
- Create a new Calculated column called LikelihoodScore and use the following formula:
- Both of the above should return a number with no decimal places
- Create a new Calculated column called RiskScore with the following formula:
When you now add a new item to your list you should get a form like this to capture the name of the risk and choose the Consequence (sometimes called impact) and Likelihood (sometimes called probability).
Good start but all we can see at the moment is the usual list of letters and numbers. To make it look pretty we need some custom XSLT. If you are not familiar with XSLT then take a quick read through my previous little mini series of blogs.
Today I have made it easy and added the files on GitHub for you to download:
I have now tried adding these files to OneDrive so hopefully that will make it easier for everyone to get them.
The XSL file includes a link to the CSS file. I have assumed you will put both files in /Style Library/custom. If this is different then you will need to change the path to the CSS file in the XSL file – it is near the top and commented so will be easy to find.
Now the easy bit. Add your list as a web part to any page and edit the web part. Under the Miscellaneous area type in the path to your XSL file (/Style Library/custom/RiskMatrix.xsl) and click OK.
You should now have a nice Risk Matrix – congratulations!
I will be presenting this and more at the Australian SharePoint Conference on Wednesday 21 March 2012 in Melbourne so do come along and say hello.