Subject: Close Lotus Notes Client through LotusScript?
You can create an empty form with the formula @Command([FileExit]) in its PostOpen event. In your LotusScript code, use workspace.ComposeDocument to compose a document using this form. The new document immediately closes the client.
Subject: Close Lotus Notes Client through LotusScript?
I have been using the code below. Found it on Notes Forum some month ago. :-))
[Declarations]
Declare Sub keybd_event Lib “user32.dll” (Byval bVk As Integer, Byval bScan As Integer, Byval dwFlags As Integer,Byval dwExtraInfo As Integer)
Sub Initialize
keybd_event 18,0,0,0 ' Alt key down
keybd_event 70,0,0,0 ' F key down
keybd_event 70,0,2,0 ' F key up
keybd_event 18,0,2,0 ' Alt key up
keybd_event 88,0,0,0 ' X key down
keybd_event 88,0,2,0 ' X key up
Subject: Nice tip. In Lotus Notes 8 you should use ALT+f4+enter instead
Nice tip Bjarne Hoeg.
Just take note: In Lotus Notes 8 you should use ALT+f4+enter instead:
[Declarations]
Declare Sub keybd_event Lib “user32.dll” (Byval bVk As Integer, Byval bScan As Integer, Byval dwFlags As Integer,Byval dwExtraInfo As Integer)
Sub Initialize
keybd_event 18,0,0,0 ' Alt down
keybd_event 115,0,0,0 ' F4 down
keybd_event 115,0,2,0 ' F4 up
keybd_event 18,0,2,0 ' Alt up
keybd_event 13,0,0,0 ' enter up
keybd_event 13,0,2,0 ' enter down