We can consume both these objects in two ways
a. In the form of variables for StateManagement.
b. In the form of events using Global.ASAX file.
Global.ASAX File :
- 1. These file is called active server application file and it should be located in root directory of projects.
- 2. A project can have only one Global.ASAX file.
- 3. It is called as application file because for every request first these file is executed and then the requested resource.
- 4. The content of Global.ASAX is all application and session evernts. We can use these file for performing unique tasks related to application.
- 5. By default in an asp.net project it is not added . we have to explicitly add it using add new item. For some of the projects Global.ASAX is compulsory and it is added along with project only like MVC, dynamic data project etc.
No comments:
Post a Comment