Report Conditioonal format

J

Junior

In a report [RptOne] -
i want [txtRcvd] to change color if its [txtRcvd] <>"X" and [txtRMK]="RSM"
how would i code the conditional statement
thanks
 
M

Marshall Barton

Junior said:
In a report [RptOne] -
i want [txtRcvd] to change color if its [txtRcvd] <>"X" and [txtRMK]="RSM"
how would i code the conditional statement


You can use Conditional Formatting (Format menu) and set its
Expression Is: to just what you have above.

If you prefer to do it with VBA, use code like this in the
Format event procedure of the section containing txtRcvd:

If [txtRcvd] <>"X" and [txtRMK]="RSM" Then
[txtRcvd].ForeColor = vbRed
Else
[txtRcvd].ForeColor = vbWhite
End If
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top