Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Conditional Background Color 1

Status
Not open for further replies.

dianemarie

Instructor
Jul 11, 2001
583
US
Hello, I have a field which the user decides whether or not to show on the report via a parameter. If the field is hidden, I want the corresponding heading hidden also. We color our heading boxes but I want the table (textbox) cell to be yellow whether the heading text is hidden or not, but if it's hidden the background color goes white. I put this expression in the background properties of the textbox to try and work around it:

=iif(Parameters!CallDate.Value = false,"Yellow","Yellow")

However, if hidden, the textbox doesn't bring in the color. Any ideas what I'm doing wrong? I've tried several varieties of the above if statement, nothing works. Thank you.
 
if the textbox is hidden you won't get any color attributes because it is hidden. You will need to set your text to "" (empty string) rather than hiding the box. That way the background colors can still be set and visible as needed and the text is not there as you are wanting.

--------------------------------------------------
"...and did we give up when the Germans bombed Pearl Harbor? NO!"

"Don't stop him. He's roll'n."
--------------------------------------------------
 
Of course!! Simple and effective. My favorites! Thanks a lot.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top