I’m wanting to cache some data in ASP.NET so that once a single cache is made, it is accesible to all users. Will HttpContext.Current.Cache do that, or is there another context’s cache I need to be accessing?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Yes, that’s exactly what it is designed for: store data that will be available to all users of the application. You may also take a look at the
@OutputCachedirective which allows you to cache entire WebForms (aspx) or fragments (ascx) on the server or on the client contrary toHttpContext.Current.Cachewhich stores objects onto the server.