Questions tagged [global-asax]

A special file in the ASP.NET framework, it provides a simplified interface to create hooks into system events in the life cycle of a web application and web pages in that application.

A special file in the ASP.NET framework, it provides a simplified interface to create hooks into system events in the life cycle of a web application and web pages in that application.

Most often used to define resources which need to be globally defined for use by all web pages and services.

1047 questions
0
votes
0 answers

How to get Cassini (and others) to always call Application_BeginRequest when requesting a URL?

I have a web application which uses a custom framework. It relies on getting an Application_BeginRequest to parse a URL and serve a proper page by Response.Output. Note it's a bit of an experiment and clearly not ASP.Net-MVC. It also does not use…
Earlz
  • 62,085
  • 98
  • 303
  • 499
0
votes
2 answers

Why Does Hit Counter(Application Variable) from Global.asax set to '0' after some time in ASP.NET?

I have about 50 application variables for each search database. In total 50 searchDB which are queried from single Search.aspx page, depending upon the query string passed in the URL it connects to Specific DB. Eg: if Search.aspx?li=1 then connect…
0
votes
1 answer

How to Set the Total Visitors count in ASP.NET for different Databases that are accessed from same Page?

I am having a Search.aspx page which is going to display the records from user entered search criteria. It get the connects to the Specific Database amongst 50 SQLServer Databases. Depending upon the QueryString passed i.e Search.aspx?ID=1 it will…
SHEKHAR SHETE
  • 5,964
  • 15
  • 85
  • 143
0
votes
2 answers

Refresh asp controls periodically

I have an aspx web form in a WCF service project that gives a status report on that service. Currently I have a Refresh button, but I'd like to automate a regular periodic refresh. I've tried two ways: A javascript inside using…
acraig5075
  • 10,588
  • 3
  • 31
  • 50
0
votes
1 answer

Castle Windsor and WCF when to register and release components

I'm using Castle Windsor to inject dependencies into several WCF services. We're also using Castle.Facilities.WcfIntegration.DefaultServiceHostFactory and castle's wcfFacility. Our services are hosted in IIS which gives me access to the Global.aspx…
dalcantara
  • 1,613
  • 2
  • 21
  • 35
0
votes
3 answers

Asp.net MVC URL routing: issue changing URL when has parameters

I need to change all the URLs in my MVC project, and thus far this has been quite simple - I've only had to change the URL string in all appropriate routes.MapRoute() in the global.asax.cs file. One link in particular is acting stubborn and won't…
valen
  • 807
  • 1
  • 16
  • 43
0
votes
2 answers

ASP.NET MVC3 HttpApplication doesn't fire events like BeginRequest, EndRequest, PostAcquireRequestState

ASP.NET MVC3 HttpApplication doesn't fire events like BeginRequest, EndRequest, PostAcquireRequestState etc. So it works fine but it doesn't fire events! I have tried to reinstall asp.net via aspnet_regiis - but there was no luck. Also i have tried…
Yuriy Anisimov
  • 825
  • 1
  • 7
  • 16
0
votes
1 answer

Global.asax Application_Start run on bin-folder update?

My question is quite simple.. What if I have an application.. and I start it, and then I assume that Application_Start will be hit.. But what if I during runtime add another assembly to the bin-folder.. would this cause the application to rebuild…
Inx
  • 2,364
  • 7
  • 38
  • 55
0
votes
1 answer

Global.asax List resets itself

So I just added a system for whitelisting my website. Here is my Global.asax. I have commented the troubled areas #region Application Methods private List _approvedIps = new List(); protected void…
Adam Schiavone
  • 2,412
  • 3
  • 32
  • 65
0
votes
1 answer

Global API security checks with ASP.Net MVC3

We are planning on using ASP.Net MVC3 to create a JSON API. For handling security we will have something like an API key, or possibly the Username/Password and maybe a timestamp. I haven't done any MVC before but I'm wondering if there isn't some…
James P. Wright
  • 8,991
  • 23
  • 79
  • 142
0
votes
3 answers

background thread in asp.net application

i run a background thread in Application_Start() in global.asax to use it like windows service but applicaton_end fire when all session is ended in my website i have a sms Business that work with webservice and i want to have agent in my server…
0
votes
6 answers

How to limit users to Login?

I have a scenario in which I have to restrict the users for login as per following details: Whenever 500th user try to login My web-site there would be a message "User login exceeds, please login later!". Only 499 users can login at a time, 500th…
Gaurav Arora
  • 2,243
  • 6
  • 40
  • 57
0
votes
1 answer

rout registration breaks when I change the url in global.asax

The following rout registration works for my asp.net MVC application routes.MapRoute("TrackingChannels", "TrackingChannels/{action}", new { controller = "TrackingChannels", action = "Index" }); When I change it to catch this url, I get…
Elad Benda
  • 35,076
  • 87
  • 265
  • 471
0
votes
1 answer

Global asax and application_endrequest asp.net

When I run my method in global.asax it doesn't run and when I use IHttp module it is working. Please give any advice. Maybe it is caused of : context.PostRequestHandlerExecute += new EventHandler(Application_EndRequest); Is it possible to call it…
Endiss
  • 699
  • 2
  • 10
  • 23
-1
votes
2 answers

Is it possible to code Jquery or Javascript in global.asax file

Hi all i am having a requirement i.e i will have image icons on my form where i have to show tool tips when i hover the mouse on that icon. Assume that i have my controls as follows on a form Bank Name Textbox Helpicon(when i mouse over on…
Vivekh
  • 4,141
  • 11
  • 57
  • 102
1 2 3
69
70