Sub Initialize Dim ws As New NotesUIWorkspace Dim uidoc As NotesUIDocument Dim askme As Integer Dim editmode As Boolean Set uidoc = ws.CurrentDocument editmode = uidoc.EditMode If editmode Then askme = ws.Prompt(PROMPT_OK, "結果", "既に編集モードです。") Else uidoc.EditMode = True End If End Sub