Does seeing the code indented help?
Code:
If (WorkOrderType = "Activation") Or (WorkOrderType = "Renewal") Then
Me.OpenDate.Enabled = True
Me.CloseDate.Enabled = True
Me.TimeStamp.Enabled = True
Else:
Me.OpenDate.Enabled = False
Me.CloseDate.Enabled = False
Me.TimeStamp.Enabled = False
End If
If (WorkOrderType = "Renewal") Or (WorkOrderType = "Deactivation") Then
If MsgBox("Search for Associated Cases", vbOKOnly, "Case Search") Then
Dim CountJobs As Long
CountJobs = DCount("SID", "WorkOrders", "L4ID=""" & Me.L4ID.Value & """")
If (CountJobs = 0) Then
MsgBox "No Associated WorkOrders Found", vbOKOnly
End If
'Else
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "WorkOrderAssociation_Query"
DoCmd.OpenForm stDocName
End If
ElseIf (WorkOrderType = "Modification") Then
If MsgBox("Do you wish to modify WorkOrder Info?", vbQuestion + vbYesNo, "Edit_WorkOrders_Query_Form") = vbYes Then
stDocName = "Edit_WorkOrders_Query_Form"
DoCmd.OpenForm stDocName
ElseIf MsgBox("Do you wish to modify Customer Data?", vbQuestion + vbYesNo, "Edit_Customer_Query_Form") = vbYes Then
stDocName = "Edit_Custoemer_Query_Form"
DoCmd.OpenForm stDocName
ElseIf MsgBox("Do you wish to modify Billing Data?", vbQuestion + vbYesNo, "Edit_Billing_Query_Form") = vbYes Then
stDocName = "Edit_Billing_Query_Form"
DoCmd.OpenForm stDocName
End If
End If
If not, the fix is attached, in my crude artistically-challenged way.