Using Cache methods in dll

  • Thread starter Thread starter g_srileka
  • Start date Start date
G

g_srileka

Shall i use Cache class and its methods for creating c# dll file.
i tried to access insert and get methods of Cache ,but i couldn't get
it ,even i imported System.Web.Caching .
i am getting
An object reference is required for the nonstatic field, method, or
property 'System.Web.Caching.Cache.Get(string)'

error while debugging
if anyone knows.plz give me the answer
 
Shall i use Cache class and its methods for creating c# dll file.
i tried to access insert and get methods of Cache ,but i couldn't get
it ,even i imported System.Web.Caching .
i am getting
An object reference is required for the nonstatic field, method, or
property 'System.Web.Caching.Cache.Get(string)'

error while debugging
if anyone knows.plz give me the answer

You can access the Cache through System.Web.HttpRuntime.Cache

Hans Kesting
 
Are you going to use this DLL in a non-web application? If so, you
might want to check out the Caching application block in the Enterprise
Application Blocks. It would be much more appropriate.

Hope this helps.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top