how to make label visible on a report if a textbox is empty

sspreyer

Registered User.
Local time
Today, 12:36
Joined
Nov 18, 2013
Messages
251
hi ,

all

can someone point me in the right direction why this code below is not working as I'm banging my head

how it works

right I'm working on a report

I have a text box that contains directory path for a picture which is showed in a image box on my report which works great. I have now created a label called "nopiclb" that has "no Pic "entered in it but I want to set the label to not visible if path1 has a file path in it but visible if path1 is empty

i put the code below in onformat event in the detail section

but is not working




Code:
 Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
If IsNull(Me.path1) = True Or Me.path1 = "" Then
 Me.Nopiclb.Visible = True
 Else
 Me.Nopiclb.Visible = False
 End If
 End Sub

thanks in advance


shane
 
Do you choose the "Print Preview", else the format event isn't triggered.
 
Do you choose the "Print Preview", else the format event isn't triggered.

thanks JHB yeah that worked lol I feel like a right bloody Idoit now

think i was having a bit of a moment...

cheers

again

shane
 
... I feel like a right bloody Idoit now
You don't need to have that feeling, the most users do not know that all features isn't available in "Report View"! :)
 

Users who are viewing this thread

Back
Top Bottom