You see, sometimes it takes people several days to capture all the REQUIRED fields or all the NON-REQUIRED fields. Because of this, I need to be sure that I can capture the correct date for both fields.
Have any ideas on what I can do to correct this??? It would be greatly appreciated if you or someone can show me exactly what I need to do.
Thank you VERY much for your assistance.
Expand|Select|Wrap|Line Numbers
- Private Sub Form_BeforeUpdate(Cancel As Integer)
- Dim FLAG_2 As Integer
- FLAG_2 = 0
- If Not IsNull(Me.Communicated_Date) Then
- FLAG_2 = FLAG_2 + 1
- End If
- If Not IsNull(Me.DescribeInjury) Then
- FLAG_2 = FLAG_2 + 1
- End If
- If Not IsNull(Me.BODY_PART_ID) Then
- FLAG_2 = FLAG_2 + 1
- End If
- If Not IsNull(Me.F_MEASURES!DATE_COMPL) Then
- FLAG_2 = FLAG_2 + 1
- End If
- If Not IsNull(Me.F_SME_INVEST_TEAM!SME_NAME) Then
- FLAG_2 = FLAG_2 + 1
- End If
- If Not IsNull(Me.F_SME_INVEST_TEAM!SME_TITLE) Then
- FLAG_2 = FLAG_2 + 1
- End If
- If Not IsNull(Me.INV_TEAM_REVIEWED) Then
- FLAG_2 = FLAG_2 + 1
- End If
- If FLAG_2 = 7 Then
- Me.DATE_NOT_REQ = Now()
- End If
- Dim FLAG_3 As Integer
- FLAG_3 = 0
- If Not IsNull(Me.SRI) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.LOC_CODE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.COST_CTR) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.INCIDENT_DATE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.INCIDENT_TIME) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.WEEKDAY_CODE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.SITE_LOC_CODE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.SITE_AREA_CODE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.DateReported) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.TimeReported) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.INCIDENT_TYPE_CODE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.IncidentDescription) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.KNOWN_FACTS) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_IMMED_FACTOR_B!IMM_FACTOR_ID) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_KEY_FACTORS!ID) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.PatientHandlingFactor) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_MEASURES!ACTION_ID) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_MEASURES!DESCRIPTION) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_MEASURES!RESPONSIBLE_PARTY) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_MEASURES!TARGET_COMP_DATE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_MEASURES!RULE_PROC) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_AUTHOR!AUTHOR_NAME) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.F_AUTHOR!AUTHOR_TITLE) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If Not IsNull(Me.EMP_INVEST_TEAM) Then
- FLAG_3 = FLAG_3 + 1
- End If
- If IsNull(Me.DATE_REQUIRED) Then
- If FLAG_3 = 24 Then
- Me.DATE_REQUIRED = Now()
- End If
- End If
- End Sub