October 2010
Intermediate to advanced
1920 pages
73h 55m
English
VirtualPathProvider ClassBefore you can use an instance of the VirtualPathProvider class, you must register it for your application. You can register a VirtualPathProvider instance with the HostingEnvironment.RegisterVirtualPathProvider() method.
You need to register the VirtualPathProvider when an application first initializes. You can do this by creating a shared method named AppInitialize() and adding the method to any class contained in the App_Code folder. The AppInitialize() method is automatically called by the ASP.NET Framework when an application starts.
For example, the following AppInitialize method registers a VirtualPathProvider named MyVirtualPathProvider:
Read now
Unlock full access