R
RobUCSD
with the code below i'm trying to limit who can edit the form to RNs only. I
get a complile error on the Then statement of, missing I can't seem to get
it to work.
Note that [VisitDate] = Date Then belongs to the line above it. (broken up
by the disscussion groups msg window.
Thanks, Rob
____________________________________________________________________
Private Sub Form_Current()
On Error GoTo Form_Current_Error
If (CurrentUser = Me.txtCreator _
And IsUserInGroup(CurrentUser(), "RNs") _
And
[Forms]![frmPtDemographicNew]![frmVisitNewEdit].[Form]![VisitDate] = Date Then
Me.AllowDeletions = True
Me.AllowEdits = True
Else: Me.AllowDeletions = False
Me.AllowEdits = False
End If
On Error GoTo 0
Exit Sub
Form_Current_Error:
MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure
Form_Current of VBA Document Form_fsubRNnotes"
End Sub
get a complile error on the Then statement of, missing I can't seem to get
it to work.
Note that [VisitDate] = Date Then belongs to the line above it. (broken up
by the disscussion groups msg window.
Thanks, Rob
____________________________________________________________________
Private Sub Form_Current()
On Error GoTo Form_Current_Error
If (CurrentUser = Me.txtCreator _
And IsUserInGroup(CurrentUser(), "RNs") _
And
[Forms]![frmPtDemographicNew]![frmVisitNewEdit].[Form]![VisitDate] = Date Then
Me.AllowDeletions = True
Me.AllowEdits = True
Else: Me.AllowDeletions = False
Me.AllowEdits = False
End If
On Error GoTo 0
Exit Sub
Form_Current_Error:
MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure
Form_Current of VBA Document Form_fsubRNnotes"
End Sub