I want to use the Caching.Cache(...) method, like so:
Cache.Insert(\"Interview Questions\", datatable, sqlcachedep)
or
Syst
Try this (from memory):
HttpApplication.Context.Cache.Insert("Reading List", datatable, sqlcachedep);
It's saying the correct thing. You should try something like:
HttpContext.Current.Cache.Insert(...);
Cache.Insert is a not a static method (static methods are indicated by an "S" near the method icon in the documentation.) You need an instance to call the Insert
method on. HttpContext.Current.Cache
returns the Cache
object associated with the current application.
You need to do
Page.Cache.Insert()
(I'm assuming you're talking ASP.Net). You're calling on Cache as the class, not as the instance of it.