C# console app to send email at scheduled times

前端 未结 8 752
北海茫月
北海茫月 2020-12-28 18:44

I\'ve got a C# console app running on Windows Server 2003 whose purpose is to read a table called Notifications and a field called \"NotifyDateTime\" and send an email when

8条回答
  •  悲&欢浪女
    2020-12-28 19:18

    Scheduled tasks can be scheduled to run just once at a specific time (as opposed to hourly, daily, etc.), so one option would be to create the scheduled task when the specific field in your database changes.

    You don't mention which database you use, but some databases support the notion of a trigger, e.g. in SQL: http://technet.microsoft.com/en-us/library/ms189799.aspx

提交回复
热议问题