Isn't the OnContextCreating event called when we call RegisterContext ?
Currently we call RegisterRoutes in Application_Start and RegisterContext is called inside this method. This method gets only called once during the application lifecycle. So few questions
1. Can I do RegisterContext in Application_Request ?( I tried this and it says duplicate context)
2. Can I associate different model to every request based on querystring?
Member
1 Points
4 Posts
Re: Issue: Connect to different database based on QueryString parameter using DynamicData
Jan 09, 2014 01:51 PM|milap_great|LINK
Isn't the OnContextCreating event called when we call RegisterContext ?
Currently we call RegisterRoutes in Application_Start and RegisterContext is called inside this method. This method gets only called once during the application lifecycle. So few questions
1. Can I do RegisterContext in Application_Request ?( I tried this and it says duplicate context)
2. Can I associate different model to every request based on querystring?
Thanks,
Milap