0

According to sending an email with lotus notes using windows command line

Run the command notes.exe mailto:[email protected]?subject="Test"?body="Test" in cmd, always open GUI instead of sending email immediately, how to send email in command line without clicking "send" button ?

1 Answer 1

1

Reference: Sendkeys from command prompt

Solve this question: send lotus email with command and do not need to click any button.

Write a vbs script:

set shell = CreateObject("WScript.Shell")
shell.run"YourLotusPath\notes.exe"
WScript.Sleep 1000
shell.run"YourLotusPath\notes.exe mailto:[email protected]?subject=Test?body=Test?attach=test.txt"
WScript.Sleep 2000
shell.SendKeys"{TAB}"
shell.SendKeys"{ENTER}"
shell.SendKeys"^(+{ENTER})"  <== Ctrl+Shift+Enter, which is lotus "send" shortcut key.
WScript.Sleep 1000
shell.SendKeys"{ENTER}"

Then, just execute the vbs script by cscript sendmail.vbs

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .