Hi to All
Sir I m having a problem. I have this code in view action formula when i select a document and click on action it changes some field values. it’s working but its showing error object variable is not set.
i m not getting where is the error.
it working fine in other server.
pls help me
Sub Click(Source As Button)
Dim session As New NotesSession
Dim db As NotesDatabase
Dim collection As NotesDocumentCollection
Dim doc As NotesDocument
Dim ws As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Set uidoc = ws.CurrentDocument
Set db = session.CurrentDatabase
Set collection = db.UnprocessedDocuments
Dim counter As Integer
counter = 0
Set doc = collection.GetFirstDocument()
'''''''''''''''Count number ofDocument in the Collection '''''''''
Dim TotalDocument As Integer
TotalDocument=Collection.Count
If TotalDocument<=0 Then
Msgbox"Please Select Dcouement !"
Exit Sub
End If
'''''''''''''''Count number ofDocument in the Collection '''''''''
While Not(doc Is Nothing)
doc.Flag="1"
doc.applicable = "Yes"
Call doc.Save(True,True)
Set doc = collection.GetNextDocument(doc)
counter = counter + 1
Wend
Msgbox counter & " Document Sucessfully Saved as confirmed Status!"
uidoc.Close
End Sub