如何在MVC 4中每5分钟从应用程序启动事件调用一个函数 [英] How do I call a function after every 5 min in MVC 4 from application start Event
本文介绍了如何在MVC 4中每5分钟从应用程序启动事件调用一个函数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你好,
我想在每5分钟后调用一个函数。写入控制器的功能。是否可以从应用程序启动事件中调用它。如果有任何其他方式请尽快与我分享。
Hi There,
I want to call a function after every 5 min. function written into controller. Is it possible to call it from application start Event. If any other way please share with me ASAP.
推荐答案
这是一篇类似问题的文章和源代码: http://dontcodetired.com/blog/post/Using-Server-Side-Timers-and -SignalR-in-ASPNET-MVC-Applications.aspx [ ^ ]
Here is an article and source code for a similar problem: http://dontcodetired.com/blog/post/Using-Server-Side-Timers-and-SignalR-in-ASPNET-MVC-Applications.aspx[^]
这篇关于如何在MVC 4中每5分钟从应用程序启动事件调用一个函数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文