检查Web应用程序是否在当前日期首次启动/浏览 [英] Checking if the web app is started/browsed for the first time in current date

查看:70
本文介绍了检查Web应用程序是否在当前日期首次启动/浏览的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道我的网络应用是否第一次启动。我需要每天检查一下,以便我可以发送提醒电子邮件。一旦我的应用程序第一次浏览邮件应该是发了。如何检查?帮助我..







提前致谢..

I want to find out if my web app is started for the first time.I need to check it on daily basis so that i could send reminder emails.As soon as my app is browsed for the first time the mails should be sent.How to check it? Help Me..



Thanks in advance..

推荐答案

第一次运行Application_Start事件将在global.asax文件中执行。 http://msdn.microsoft.com/en-us/library /vstudio/ms178473(v=vs.100).aspx [ ^ ]



但是,这是有人第一次在App之后访问应用程序池实例已启动。



要检查当天的第一次,您只需将其记录在某个地方的数据库中,您可以使用Global.asax中的Session_Start来查看是否该用户是当天的第一个用户。
The first time it runs the Application_Start event will execute in your global.asax file. http://msdn.microsoft.com/en-us/library/vstudio/ms178473(v=vs.100).aspx[^]

However, that is the first time someone visits the application after the App pool instance has been started.

To check for first time in the day you'll just have to record it in the db somewhere and you could use Session_Start in Global.asax to check to see if that user is the first for the day or not.


这篇关于检查Web应用程序是否在当前日期首次启动/浏览的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆