如何让一个Cache的存活期同Session
我想在Session_End事件里面清空一个Cache,这样写的
if(null != (DataSet)Cache["dsHouse"])
{
Cache.Remove("dsHouse");
}
编译不能通过"The name'Cache' does not exist in the class or namespace 'Prophet.Global'"
后来我在gobal.asa里面增加了System.Web.Caching命名空间
编译不能通过"'System.Web.Caching.Cache' denotes a 'class' where a 'variable' was expected"
我只是希望在工程结束的时候,清除一个Cache,怎么实现(好象Cache的存活期同Session)