{"id":26,"date":"2008-10-16T09:00:53","date_gmt":"2008-10-16T07:00:53","guid":{"rendered":"http:\/\/www.calvert.ch\/maurice\/?p=26"},"modified":"2011-05-10T22:16:09","modified_gmt":"2011-05-10T20:16:09","slug":"project-management-dashboard-excel-with-traffic-lights","status":"publish","type":"post","link":"https:\/\/www.calvert.ch\/maurice\/2008\/10\/16\/project-management-dashboard-excel-with-traffic-lights\/","title":{"rendered":"Project Management Dashboard &#8211; Excel with traffic lights"},"content":{"rendered":"<p>Many traffic-light solutions for Excel exist but all the ones I tried only work for a single light, and I needed an array like this:<br \/>\n<a href=\"http:\/\/www.calvert.ch\/maurice\/files\/2008\/10\/project-progress-dashboard-overview1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-30\" src=\"http:\/\/www.calvert.ch\/maurice\/wp-content\/uploads\/2008\/10\/project-progress-dashboard-overview1-300x162.jpg\" alt=\"\" width=\"300\" height=\"162\" srcset=\"https:\/\/www.calvert.ch\/maurice\/files\/2008\/10\/project-progress-dashboard-overview1-300x162.jpg 300w, https:\/\/www.calvert.ch\/maurice\/files\/2008\/10\/project-progress-dashboard-overview1.jpg 525w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>I wanted to create a light by simply typing a formula in the light&#8217;s cell, with the colour of the light determined by a value in cell elsewhere. The light must change colour as soon as the underlying value changes. This wasn&#8217;t as simple to implement as I thought, but in the end a bit of VBA led to this formula :<br \/>\n    <span style=\"color: #000080\">=trafficlight(Sheet2!B4,Sheet2!B$3,Sheet2!C$3)<br \/>\n<\/span>and the rest of the lights are created by dragging this formula right and down.<\/p>\n<p>The parameters to the TrafficLight function are:<\/p>\n<ol>\n<li>The cell containing the value which determines the colour of the light.<\/li>\n<li>The threshold to change from red to amber.<\/li>\n<li>The threshold to change from amber to green.<\/li>\n<\/ol>\n<p>in this example, the Sheet2 looks like this:<br \/>\n<a href=\"http:\/\/www.calvert.ch\/maurice\/files\/2008\/10\/consolidatedcorner1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-29\" src=\"http:\/\/www.calvert.ch\/maurice\/files\/2008\/10\/consolidatedcorner1.jpg\" alt=\"\" width=\"202\" height=\"85\" \/><\/a><\/p>\n<p><a href=\"http:\/\/www.calvert.ch\/maurice\/files\/2008\/10\/consolidatedcorner.jpg\"><\/a><\/p>\n<p>Project 1 has a value of 64 and thus is amber.<\/p>\n<p>Here&#8217;s a ZIP file with the .XLS and the images <a href=\"http:\/\/www.calvert.ch\/maurice\/wp-content\/uploads\/2008\/10\/project-progress-dashboard.zip\">project-progress-dashboard<\/a>, feel free to use it as you see fit.<\/p>\n<p>Notes:<\/p>\n<ol>\n<li>The red and green images have an exclamation mark and a tick superimposed so that they are recognisable on a black-and-white printout.<\/li>\n<li>You must keep the 3 GIF files in the same directory as the spreadsheet.<\/li>\n<li>There is one bug. If you resize a cell containing a light such that the light is no longer contained within the cell&#8217;s boundaries, the light will not be deleted when its underlying value changes (you end up with an orphaned light). To fix this, there is a &#8220;Remove lights&#8221; button; clicking it will delete all images and pressing F9 will re-generate correctly.<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>Many traffic-light solutions for Excel exist but all the ones I tried only work for a single light, and I needed an array like this: I wanted to create a light by simply typing a formula in the light&#8217;s cell, <a href='https:\/\/www.calvert.ch\/maurice\/2008\/10\/16\/project-management-dashboard-excel-with-traffic-lights\/' class='excerpt-more'>[&#8230;]<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,11,13],"tags":[19,37],"class_list":["post-26","post","type-post","status-publish","format-standard","hentry","category-finance","category-technology","category-work","tag-excel","tag-traffic-lights","category-3-id","category-11-id","category-13-id","post-seq-1","post-parity-odd","meta-position-corners","fix"],"_links":{"self":[{"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/posts\/26","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/comments?post=26"}],"version-history":[{"count":2,"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/posts\/26\/revisions"}],"predecessor-version":[{"id":581,"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/posts\/26\/revisions\/581"}],"wp:attachment":[{"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/media?parent=26"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/categories?post=26"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.calvert.ch\/maurice\/wp-json\/wp\/v2\/tags?post=26"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}