Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static System.Web.Caching.Cache Cache
- {
- get
- {
- if(cache == null)
- {
- if (System.Web.HttpContext.Current != null)
- {
- //asp.net
- cache = System.Web.HttpContext.Current.Cache;
- }
- else
- {
- //windows service
- cache = System.Web.HttpRuntime.Cache;
- }
- }
- return cache;
- }
- }
Add Comment
Please, Sign In to add comment