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

Knowing when a form is visible 2

Status
Not open for further replies.

norason

Programmer
Jan 28, 2009
139
US
Every search I've done regarding how to know when a form is visible says basically the same thing:

If fmMaintenance.Visible = True Then...

but I've tried that and fmMaintenance.Visible is true before it has been called. Also, somehow fmMaintenance is called when I step passed the:

If fmMaintenance.Visible = True Then

line. HUH?

Why is .visible always true and why does it call fmMaintenace?



Public Sub CmdCallFlowChart_Click()
If fmMaintenance.Visible = True Then
Debug.Print "Maintenance is on"
Dim IBeep
For IBeep = 1 To 3 ' Loop 3 times.
Beep ' Sound a tone.
Next
MsgBox "Cannot retrieve charts while Maintenance screen is acive", vbExclamation, "Chart Note"
Exit Sub
End If
Call FmFlowCharts.Show
Exit Sub
End Sub
 
Even though they look like a cuddly sort of thing, Wombats are quite ferocious, can run at 35 mph, rip a man apart with their front claws and stink to high heaven because they pee on themselves to keep cool in summer!
 
Excellent! I'd hate to be using any sort of cute, cuddly variables ...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top