ASP.NET程序中常用代码汇总(一)[1]

[入库:2006年2月23日] [更新:2007年3月24日]

本文简介:

1. 打开新的窗口并传送参数:

//传送参数:
response.write("<script>window.open(’*.aspx?id="+this.DropDownList1.SelectIndex+"&id1="++"’)</script>")
  
//接收参数:
string a = Request.QueryString("id");
string b = Request.QueryString("id1");
2.为按钮添加对话框
Button1.Attributes.Add("onclick","return confirm(’确认?’)");
button.attributes.add(
"onclick","if(confirm(’are you sure?’)){return true;}else{return false;}")

本文关键:ASP.NET程序中常用代码汇总(一)
  相关方案
Google
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top