![]() |
|
[Python] Send data in email attachment every hour - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118) +---- Thread: [Python] Send data in email attachment every hour (/showthread.php?tid=5616405) |
Send data in email attachment every hour - ASlopaR - May 6, 2017 Hi, I want send data in email attachment (.txt file) every hour remote.. And if I compiles to exe (with py2exe) get error on line Code while True:Actually code to send email: Code def mail(serverURL=smtp.seznam.cz, sender='', to='', subject='', text=''):* - Riԁdle - May 6, 2017 (May 6, 2017 05:17 AM)ASlopaR Wrote: Hi, I want send data in email attachment (.txt file) every hour remote.. And if I compiles to exe (with py2exe) get error on line your while statement doesn't look indented Code if __name__ == '__main__':* - Pillus - May 6, 2017 Would be great if you could include the error as well? :) There is normally a few lines called Traceback, that would help out a lot. * - ASlopaR - May 6, 2017 Actually problem is removed, and I get new problem. I have included to Python 2.7.13 APScheduler module (module version 3.3.1) And I will import in code: Code from apscheduler.scheduler import SchedulerError message: Traceback (most recent call last): File "<pyshell#2>", line 1, in <module> from apscheduler.scheduler import Scheduler ImportError: No module named apscheduler.scheduler * - hunter24957 - May 6, 2017 Code serverURL=smtp.seznam.czServerURL argument needs to be a string, like so: Code serverURL='smtp.seznam.cz' |