MATLAB: How to send email reminders using sendmail

csvemailreminderssend datesendmail

Hi, I’m trying to set up an email reminder system, where I can send emails at certain dates. I’ve been looking at the sendmail function but I haven’t found any information as to how I can edit the send date. I.e I have a simple csv, with email addresses and appointment reminders and want to send email reminders based on those dates.
Any help would be much appreciated!

Best Answer

Is that a 3rd party function or are you refering to sendmail()? It is not possible to set the send-date using sendmail(). The email is sent when the command it executed. Instead, you could write a program that could be run daily where a table contains the email information in one column and the send-date in another column. If today's date is the send date, the program could send the email and then remove the entry from the table.
Alternatively you could create a timer object that controls when the email is sent but if matlab shuts down (or if the timer object is deleted) the emails will never be sent.