I am using data report with ms access database. I want to the rptTextbox color to change based on the value of the the recordset field. Eg to appear red if the field is "FAIL" and black if it is "PASS". My code is
cmdShowReport_C lick
' '''''''the STATUS field is bound to Text1. """"" rs is recordset
If rs.Fields("STAT US") < 40 THEN
DataReport1.Sec tions(Section1) .Controls("Text 1") =vbRed
else
DataReport1.Sec tions(Section1) .Controls("Text 1") =vbBlack
End if
It worked for only the first page of the report. For the other pages, the color was red whether or not the STATUS was "FAIL" . (The first RECORD is "fail")
Pls i need help
cmdShowReport_C lick
' '''''''the STATUS field is bound to Text1. """"" rs is recordset
If rs.Fields("STAT US") < 40 THEN
DataReport1.Sec tions(Section1) .Controls("Text 1") =vbRed
else
DataReport1.Sec tions(Section1) .Controls("Text 1") =vbBlack
End if
It worked for only the first page of the report. For the other pages, the color was red whether or not the STATUS was "FAIL" . (The first RECORD is "fail")
Pls i need help