If form is Open Code Question?

  • Thread starter Thread starter Dave
  • Start date Start date
D

Dave

I have form named TimeCards and from there I sometimes open
another form named Customers
On close event of the form Customers is the below code so that the main form
is visible again.
If TimeCards form is open , I need for the form frmAutoPayrollReport
to be invisible.
Can this be done ??

Thanks,

Dave



Forms!frmAutoPayrollReport.Visible = True
 
Hi,
You can use this function to see if a form is open:
Public Function IsOpen(strForm As String)
IsOpen = (SysCmd(acSysCmdGetObjectState, acForm, strForm) > 0)
End Function

HTH
Danm Artuso, MVP
 
Back
Top