asp.net中解决页面刷新后字体等变大的问题
protected void Page_Load(object sender, EventArgs e)
{
if (Request.Cookies["login"] != null)
{
this.Button1.Attributes.Add("onclick", "if(!confirm('确实要订购吗?')) return false;");
}
}
protected void Button1_Click(object sender, EventArgs e)
{
Response.Write("<script>alert('当前购物车中,没有商品');</script>");
return;
}
把上面的改为:
protected void Button1_Click(object sender, EventArgs e)
{
//Page.RegisterStartupScript("ServiceManHistoryButtonClick", "<script>alert('当前购物车中,没有商品');</script>");
//或下面都可,上面第一个参数随便起,不要重复.
Response.Write("<script>alert('当前购物车中,没有商品');</script>");
Response.Write(" <script>document.location=document.location; </script>");
相关文档:
在ASP.NET应用程序常常会遇到需要从Excel文件中读取数据或将数据写入Excel的需求。一般来讲,在ASP.NET中读写Excel文件有四种解决方案。
1.1.1 使用OLE DB
使用OLE DB可以以查询数据库的方式来读取Excel文件,因为在某种程度上Excel表格可以看成是一张一张的数据表。其二者的主要区别在于所使用的数据引擎不一样。使用OLE ......
作者:敖士伟
在Fedora 12上的安装过程
一、mono安装
yum install gcc gcc-c++ bison pkgconfig glib2-devel gettext make libgdiplus Cairo
wget http://ftp.novell.com/pub/mono/sources/mono/mono-2.6.1.tar.bz2
tar jxvf mono-2.6.1.tar.bz2
cd mono-2.6.1
./configure --prefix=/usr
make
make install
安装 ......
如果你已经有较多的面向对象开发经验,跳过以下这两步:
第一步 掌握一门.NET面向对象语言,C#或VB.NET。
我强烈反对在没系统学过一门面向对象语言的前提下去学ASP.NET。
ASP.NET是一个全面向对象的技术,不懂面向对象,那绝对学不下去!
第二步 对.NET Framework类库有一定的了解
可以通过开发Windows Form应用 ......