July 26, 2012 at 2:03 pm
I have a Reporting Services report that has a textbox which contains the number of minutes a delivery was late. The following values would be in one textbox:
31, 29, 29, 28, 25, 25, 25, 25, 27, 27, 27,
56, 54, 55, 52, 51, 50, 51, 50, 49, 39, 32,
31, 24, 16, 10, 9, 8, 8, 7, 27, 24, 24, 24,
26, 30, 29, 30, 37, 37, 38, 37, 38, 38, 38,
40, 41, 41, 43, 42, 42, 42, 41, 34, 34, 34
What I want to do is search each textbox for any delivery that was 30 minutes or more late (see bold minutes above). If there is at least one delivery that is 30 or more minutes late, I would like to change the color of the text to "Red".
Is there a why to do this using a custom code function or a built-in function?
All suggestions will be appreciated.
July 27, 2012 at 7:08 am
While this is technically possible, you'd make life a lot easier by displaying the results from the data source in a Tablix as individual cells then using a basic expression on the colour property.
However, if you really need to do it, you could right click on the expression placeholder and go to placeholder properties and set the markup type to HTML. Then you'd need to create a function that parsed the text, split the strings, converted to integers and then appended colour tags to the relevant rows (e.g. <FONT COLOR="red">42</>) and sent back the completed string to the expression (or append this text in the code that's creating the comma seperated list in the first place).
Seriously though, I'd re-think how you're displaying the report. Each delivery should really be in it's own cell...
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply