Dear all,
I have written the script below in the QueryModeChange and it always pop out “Type Mismatch” error when I try to edit a document. Can anyone please help to check what’s wrong with the script. Thank you.
Dim ws As New NotesUIWorkspace
Dim ss As New NotesSession
Dim db As NotesDatabase
Dim uidoc As NotesUIDocument
Dim accessrole As Boolean
Set db = ss.CurrentDatabase
Set uidoc = ws.CurrentDocument
Const role = “@IsNotMember(@Name([Abbreviate]; @UserName); Createby : Participant)”
accessrole = Evaluate(role)
If accessrole = True Then
Messagebox "You are not authorised to edit this document !"
Continue = False
Exit Sub
Else
Continue = True
End If