Solved

Excel VBA using Autohotkey app with Outlook mail send

Posted on 2014-04-09
6
866 Views
Last Modified: 2014-04-09
Hi

I just downloaded Autohotkey as I was told that it could automatically click the send button
when I run Excel VBA code to display multiple mail messages.
I have no idea as to how to set this up with Autohotkey. Can someone please help?
I found the following but am not sure how to implement it
Thanks
0
Comment
Question by:murbro
  • 3
  • 3
6 Comments
 
LVL 35

Expert Comment

by:Kimputer
ID: 39988923
In the System tray, Autohotkey, Edit:

add to the top of the script:

#Persistent
SetTimer,CheckForMsgBox2,200
return

CheckForMsgBox2:      ;Closes popup windows
IfWinExist, Microsoft Office Outlook ahk_class #32770
	ControlClick, Button3, Microsoft Office Outlook ahk_class #32770, Allow
	ControlClick, Button4, Microsoft Office Outlook ahk_class #32770, Allow
return

Return

Open in new window


Give the Reload script command (systray again) and it should work
0
 

Author Comment

by:murbro
ID: 39988951
Hi

I am not sure where the tray is. If I click on the Autohotkey icon I get the following message. I click yes and nothing happens

1
0
 
LVL 35

Expert Comment

by:Kimputer
ID: 39988975
The System Tray is where all the small icons are, the usual default location is bottom right corner. It's the green "H" icon, right mouse click on it.
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 

Author Comment

by:murbro
ID: 39989045
Hi
When I open it I see the following text. Do I just overwrite it? Or do I add the code you mentioned at the top? Thanks
Script lines most recently executed (oldest first).  Press [F5] to refresh.  The seconds elapsed between a line and the one after it is in parentheses to the right (if not 0).  The bottommost line's elapsed time is the number of seconds since it executed.

---- C:\Users\murbro\Documents\AutoHotkey.ahk
016: Return (659.90)

Press [F5] to refresh.
0
 
LVL 35

Accepted Solution

by:
Kimputer earned 500 total points
ID: 39989711
I said, right mouse click on the green H icon in the system tray. Then Edit, then add the provided code on top of the file, save it, right mouse click on icon again, Reload script.
0
 

Author Closing Comment

by:murbro
ID: 39989776
Thanks very much
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
In this step by step procedure, you will come to know the details of creating an Outlook meeting in 2007, 2010, 2013 & 2016.
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

825 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question