Outlook Application.OnTime not working in Outlook VBA

Joined
Feb 21, 2018
Messages
216
Reaction score
86
Hi,

I want to schedule send/recieve after every 2 minutes...

timestring = "00:02:00"
TimeToRun = Now + TimeValue(timestring)
Application.OnTime TimeToRun, "Sync"

This logic works fine in Excel-VBA but not in Outlook VBA. Outlook VBA does not recognize :
Application.OnTime


Any suggestions, please.
 
If you want to schedule a send/receive every two minutes you can do it through the options - just go to File > Options > Advanced > Send/Receive and then set up the schedule you want. Hope this helps!
 
Back
Top