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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Reports/Text Boxes/Don't Print IF... 1

Status
Not open for further replies.

pdgnw

Technical User
Aug 10, 2000
6
US
In a report, in a text box, can i specify NOT to print the data in the text box if that data meets certain criteria?

For example, for every record for which Text Box Z contains a word which begins with "W", leave that information out. Print everything else in the report, but just leave out the data from Text Box Z for any records in which the data in Text Box Z begins with the letter "W"? Thanks!
 
In the OnFormat event of your reports detail section use and If statement.

If Me.Field = "W" Then
Me.Field = ""
End If
 
Two questions:

Would it work to set the fields visible property to NO rather than change the value?

If pdgnw is checking the first letter of the field shouldn't the expression be if Left(Me.Field, 1) = W?

Larry De Laruelle
larry1de@yahoo.com

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top