Hide a field in a report?

Vallan

Registered User.
Local time
Today, 15:09
Joined
Jan 16, 2008
Messages
46
Maybe this have been upp before.

I am trying to hide a field in a report if anothe field is true.

I get value is missing by this code.

Test_ink is an yes/no

Anyone who se whats wrong?

I can use this in forms with success but not in reports.

Matt

Code:
Private Sub Report_Open(Cancel As Integer)
If Me![test_ink] = True Then
    Me![volume_ink].Visible = False
Else
    Me![volume_ink].Visible = True
End If

End Sub
 
is the field in the detail section

if so you need to do it in the detail_format event or possibly the detail_print event, but not in the form open event.
 
What i want is this.

In as report i have 3 fields.

Field1.....Hello

Field2.....Bye

Field3.....Yes/No

I want to hide Field2 if Field3 is true.

if Field3 is false then i want to hide Field1
 
That has to be done in the OnFormat and/or OnPrint event of the section that will be printing Field1 and Field2. Field3 will ALSO have to be defined in that same section, but as .Visible = False unless you really do want to print Field3
 

Users who are viewing this thread

Back
Top Bottom