in

 

Conditional formatting - Displaying image based on field value

Last post 05-06-2008 12:06 PM by Steve Thompson. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 03-08-2008 1:03 AM

    • gost
    • Top 75 Contributor
    • Joined on 02-15-2007
    • Slovakia, Europe
    • Posts 9

    Conditional formatting - Displaying image based on field value

    Hi,

    Based on the HEALTH field value, I wanted to display different image in my status report (kind of traffic light images). I set up string variable and my expression definition is the same as in your manual (if([Health]='On Plan')then('Green')else if([Health] ='Needs Attention')then('Amber')else('Red')) and my values are Green, Amber and Red. I was successful to format e.g. certain column based on the HEALTH field value. But then I wanted to have image displayed based on the same condition. I used URL Source Variable to define the different paths for the images. Unfortunately, got following error message:

    "An error on or around the position '3'. The variable named '[Health]' is invalid."

    Can you please advise how to make it work? Could not find it anywhere in your manual or help.

    Thanks!

    stano

  • 03-19-2008 1:49 PM In reply to

    • emarone
    • Top 10 Contributor
    • Joined on 09-19-2006
    • Seattle, WA
    • Posts 268

    Re: Conditional formatting - Displaying image based on field value

    I experimented with this several months ago when I was first learning the new WI reporting tools, and I was able to accomplish this by suppressing the text value and then applying a conditional background image in the Health column.  It wasn't exactly what I was shooting for, but it produced the intended result.  The only caveat was that the images needed to be pre-sized to fit in the space provided in the colum (I think 30x30px worked pretty well for me).

    Sorry I couldn't be of more specific help, but hopefully it gives you another direction to try.  One of my colleagues who has more practical experience with report formatting might be able to offer other suggestions.

    Erik Marone | Daptiv Product Manager
  • 05-06-2008 11:16 AM In reply to

    Re: Conditional formatting - Displaying image based on field value

    Once you have your conditional string set up, applied to the cell column and you are ready to set the conditional format:

    1. go into the Condition Explorer, choose the color option you want to set and then select the unlock button at the top (looks like a padlock).  
    2. Drag an image object over from the insertable objects pane into the unlocked cell where the image is to appear and insert the URL (you must reference the image from a hosted web page, we can not yet upload images onto our servers). 

     You do have to set the image size format and such to get it to display properly.  I will have a write up with more specific steps since it's been awhile since I've done this, but I have done it successfully - hopefully this will get you moving in the right direction.

     Also, our help guides are more of a discussion about basic reporting lessons and clarification about our Daptiv data items.  Many report writing guides and help can be found in bookstores or online if you look for Cognos report writing tools since that is the engine we're using.

    Steve Thompson | Solutions Consultant
    Daptiv


  • 05-06-2008 12:06 PM In reply to

    Re: Conditional formatting - Displaying image based on field value

    I did a write up for you here:

     

    http://community.daptiv.com/forums/t/1479.aspx

     

     

    Steve Thompson | Solutions Consultant
    Daptiv


Page 1 of 1 (4 items)

Navigate: Home | Blogs | Forums | Solution Library  Get Help:  Contact | Feedback | FAQ   Terms of Use:  Terms & Conditions | Privacy Policy