title: Crystal Reports 2008 - Changing background color
body: <p>I have a subreport, and in the Group Footer, I have string, that I am trying to change the background color using the following code.  </p>
  
  <p>If WorkID IS equal to the Technical.workId or the Development.WorkId, then the color code works, but the other items are solid black.</p>
  
  <p><img src="https://i.stack.imgur.com/vPSxQ.png" alt="Example 1"></p>
  
  <p>If If WorkID IS NOT equal to or null to the Technical.workId or the Development.WorkId, the my report is blank.</p>
  
  <p><img src="https://i.stack.imgur.com/nztn4.png" alt="Example 2"></p>
  
  <pre><code>if 
  {?Pm-DB.ID}={Work.Num} 
  and {Work.WorkID}&lt;&gt;{Technical.workId}
  and {Work.WorkID}&lt;&gt;{Development.WorkId} Then crNoColor
  else if
  (
  {?Pm-DB.ID}={Work.Num} 
  and {Work.WorkID}={Development.WorkId} 
  and {Development.PlanName}={Project.ProjectName}
  and {Development.devStatus} = "R" )
  then crRed
  else if (
  {?Pm-DB.ID}={Work.Num} 
  and {Work.WorkID}={Development.WorkId} 
  and {Development.PlanName}={Project.ProjectName}
  and {Development.devStatus} = "A" )
  then crYellow
  else if (
  {?Pm-DB.ID}={Work.Num} 
  and {Work.WorkID}={Tech.workId}
  and ({Resource.Team Name}like "Tech*") 
  and {Technical.TechStatus} = "R" )
  then crRed
  else if (
  {?Pm-DB.ID}={Work.Num} 
  and {Work.WorkID}={Tech.workId}
  and ({Resource.Team Name}like "Tech*") 
  and {Technical.TechStatus} = "A" )
  then crYellow
  else if (
  {?Pm-DB.ID}={Work.Num} 
  and {Work.WorkID}={Tech.workId}
  and ({Resource.Team Name}like "QA*") 
  and {Technical.TechStatus} = "R" )
  then crRed
  else if (
  {?Pm-DB.ID}={Work.Num} 
  and {Work.WorkID}={Tech.workId}
  and ({Resource.Team Name}like "QA*") 
  and {Technical.TechStatus} = "A" )
  then crYellow
  </code></pre>