Conditional Formatting that Opens Form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have conditional formatting set up (see below) and I would also like to
open a form if the conditions exist. Can someone help me. My form name is
"CRITICAL STATION FORM" and it's a pop up form. Thank you.

Public Function fTestConditions(strLine, strDesc, strWorkStation)
If strLine = "JS" and strDesc = "Bonder" and strWorkStation = "Workstation
#4" then
fTestConditions = True
ElseIf strLine = "JS" and strDesc = "FLA" and strWorkStation = "Workstation
#9" then
fTestConditions = True
.....
END IF
 
I have conditional formatting set up (see below) and I would also like to
open a form if the conditions exist. Can someone help me. My form name is
"CRITICAL STATION FORM" and it's a pop up form. Thank you.

Public Function fTestConditions(strLine, strDesc, strWorkStation)
If strLine = "JS" and strDesc = "Bonder" and strWorkStation = "Workstation
#4" then
fTestConditions = True
ElseIf strLine = "JS" and strDesc = "FLA" and strWorkStation = "Workstation
#9" then
fTestConditions = True
....
END IF

Public Function fTestConditions(strLine, strDesc, strWorkStation)
If (strLine = "JS" and strDesc = "Bonder" and strWorkStation =
"Workstation #4") OR (strLine = "JS" and strDesc = "FLA" and
strWorkStation = "Workstation #9") Then
DoCmd.OpenForm "CRITICAL STATION FORM", , , , , acDialog
End If

The above will open the form in Dialog. Is that why you have the form
as Pop-up?
 
Back
Top