If Me.Active = False Then
If MsgBox("Are you sure you want to inactivate the selected user", vbYesNo) = vbYes Then
DoCmd.RunSQL "Update Country " & _
"INNER JOIN tblUser ON [Country].[Lead] = [tblUser].[UserID]" & _
"SET [Country].[Lead] = ," & _
"[Country].[BackUp] = ," & _
"[Country].[sLead] = ," & _
"[Country].[sBackUp] = ," & _
"[Country].[icUpdateRDO] = ," & _
"WHERE ([tblUser].[UserID] =)" & Me.UserID
Else
Me.Active = True
Exit Sub
End If
Else
Me.Active = True
End If
End Sub
If MsgBox("Are you sure you want to inactivate the selected user", vbYesNo) = vbYes Then
DoCmd.RunSQL "Update Country " & _
"INNER JOIN tblUser ON [Country].[Lead] = [tblUser].[UserID]" & _
"SET [Country].[Lead] = ," & _
"[Country].[BackUp] = ," & _
"[Country].[sLead] = ," & _
"[Country].[sBackUp] = ," & _
"[Country].[icUpdateRDO] = ," & _
"WHERE ([tblUser].[UserID] =)" & Me.UserID
Else
Me.Active = True
Exit Sub
End If
Else
Me.Active = True
End If
End Sub