【ASP.net技巧】asp.net弹出窗口 返回值
刚刚 看到这么一个问题,这里也做个标记:http://topic.csdn.net/u/20080411/14/7b0f9da5-0413-4149-91e9-72c3df3018a3.html?seed=327251592
第一种方式:
//在Visual Studio 2008中调试通过
testPop_Page.aspx:主页面ASPX代码
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<script type="text/javascript" >
function Pop()
{
var result = showModalDialog('testPop_downs.aspx', 'subpage', 'dialogWidth:800px;dialogHeight:600px;center:yes;help:no;resizable:yes;status:no'); //打开模态子窗体,并获取返回值
document.getElementById("txt_id").value=result.split("'")[0]; //返回值分别赋值给相关文本框
document.getElementById("txt_name").value=result.split("'")[1];
document.getElementById("txt_pwd").value=result.split("'")[2];
}
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:TextBox ID="txt_id" runat="server" ></asp:TextBox>
<asp:TextBox ID="txt_name" runat="server" ></asp:TextBox>
<asp:TextBox ID="txt_pwd" runat="server" ></asp:TextBox>
<br />
<asp:Button ID="btnPop" runat="server" Text="PoPWindows" OnClientClick ="Pop()"
&nbs
相关文档:
概述:
本文基于ASP.NET 2.0的源代码,对ASP.NET 2.0运行时进行了简要的分析,希望能帮助你理解ASP.NET 2.0中请求处理过程及页面编译模型。
关键字:
ASP.NET 2.0运行时,原理,请求处理,页面编译,ASP.NET 2.0 HTTP Runtime
主要类:
&nb ......
asp.net(C#)字符串加密
2010-03-12 09:59
using System;
using System.Collections.Generic;
using System.Text;
using System.Security.Cryptography;//Cryptography密码术
namespace DAL
{
......
CTRL + SHIFT + B生成解决方案
CTRL + F7 生成编译
CTRL + O 打开文件
CTRL + SHIFT + O打开项目
CTRL + SHIFT + C显示类视图窗口
F4 显示属性窗口
SHIFT + F4显示项目属性窗口
CTRL + SHIFT + E显示资源视图
F12 转到定义
CTRL + F12转到声明
CTRL + ALT + J对象浏览
CTRL + ALT + F1帮助目录
CTR ......
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
ViewState["BackUrl"] = Request.UrlReferrer.ToString();
}
}
/// <summary>
/// 返回按钮点击事件
/// </summary& ......
数据绑定控件比较(Reapter\DataList\GridView\DatailsView\FormView):
1.插入功能方面:
DetailsView和FormView具有插入功能,其它控件没有
2.模板
DataList\FormView\Repeater三种必须编辑模板,而
GridView和DetailsView只有在将列转换成模板列以后才会出现各种模板.
3.自动分页功能
GridView ,DetailsView和FormView ......