日期:2014-05-18 浏览次数:20579 次
public class PageBase : System.Web.UI.Page
{
#region 变量声明
public string strColor;
#endregion
#region 本类构造函数
public PageBase()
{
strColor="#cc00ff";
}
#endregion
}
------解决方案--------------------
自已写个类
public static System.Drawing.Color TheColor
{
get
{
if (System.Web.HttpContext.Current.Session["TheColor"] != null)
{
return (System.Drawing.Color)System.Web.HttpContext.Current.Session["TheColor"];
}
else
{
return new System.Drawing.Color();
}
}
set
{
System.Web.HttpContext.Current.Session["TheColor"] = value;
}
}
------解决方案--------------------