I have a batch driven vbscript for daily and weekly (zipped) backups.
I want to backup my mail.
I need to close Outlook and save before zipping the Outlook mail files.
I can close Outlook using vbscript or batch file... whatever is easier.
How can I close Outlook?
I came up with this script but I am trying no to use sendkeys, because I am not sure if Outlook will be activated (visible) and sendkeys may be sent to another running application.
set ws = CreateObject("WScript.shell")
ws.Run "Outlook"
WScript.sleep 300
ws.AppActivate "Inbox - Microsoft Outlook"
WScript.sleep 300
ws.sendkeys "%f+L" ' alt-f
set ws = Nothing
Any idea?
Any help is welcomed, thanks in advance.
Regards
Dominique G. Schneider
I want to backup my mail.
I need to close Outlook and save before zipping the Outlook mail files.
I can close Outlook using vbscript or batch file... whatever is easier.
How can I close Outlook?
I came up with this script but I am trying no to use sendkeys, because I am not sure if Outlook will be activated (visible) and sendkeys may be sent to another running application.
set ws = CreateObject("WScript.shell")
ws.Run "Outlook"
WScript.sleep 300
ws.AppActivate "Inbox - Microsoft Outlook"
WScript.sleep 300
ws.sendkeys "%f+L" ' alt-f
set ws = Nothing
Any idea?
Any help is welcomed, thanks in advance.
Regards
Dominique G. Schneider