Sub Exiting(Source As Field)
Dim workspace As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Dim doc As NotesDocument
Dim eval As Variant
Set uidoc = workspace.CurrentDocument
Set doc = uidoc.Document
eval = Evaluate("@ProperCase(Subject)", doc)
Call doc.ReplaceItemValue("Subject", eval)
Call doc.Save(True, False)
End Sub
Sub Click(Source As Button)
Dim workspace As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Dim doc As NotesDocument
Dim sumAmounts As Variant
Set uidoc = workspace.CurrentDocument
Set doc = uidoc.Document
sumAmounts = Evaluate("@Sum(Amounts)", doc)
Messagebox("Sum of Amounts = " & sumAmounts(0))
End Sub