简体   繁体   中英

Sending emails in python while using PyHook in intervals

I'm using pyHook to hook the keyboard and the mouse actions. A log of the hooks is being created while the program is running. I want to send the log to an email every 5 minutes - while the PunpMessages is still working and the hooking action is still running. I know how to send emails in python, however, I don't know how to do it every fixed interval.

you can try python schedulers to call your methods on given interval.

You may want to look at this module: http://packages.python.org/APScheduler/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM