在类中使用page对象用HttpContext.Current

比如在类中要使用Cache,用HttpContext.Current.Cache

Response,Request等一样.

如果要使用Page则:

Page p=(Page)HttpContext.Current.Handler;

原文地址:https://www.cnblogs.com/zxjyuan/p/1271984.html