ATLASTEST UPDATAPLANL
来源:互联网 发布:应收账款软件 编辑:程序博客网 时间:2024/04/28 03:48
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>无标题页</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:test123ConnectionString %>"
SelectCommand="SELECT [id], [name] FROM [test001]"></asp:SqlDataSource>
</div>
<atlas:ScriptManager ID="sdk" EnablePartialRendering="true" runat="server"></atlas:ScriptManager>
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True" DataSourceID="SqlDataSource1"
DataTextField="id" DataValueField="id">
</asp:DropDownList>
<asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:test123ConnectionString %>"
SelectCommand="SELECT [id], [tid], [name] FROM [test002] WHERE ([tid] = @tid)">
<SelectParameters>
<asp:ControlParameter ControlID="DropDownList1" Name="tid" PropertyName="SelectedValue"
Type="Int32" />
</SelectParameters>
</asp:SqlDataSource>
<atlas:UpdatePanel ID="dsf" runat="server">
<ContentTemplate>
<asp:GridView ID="GridView1" runat="server" AllowPaging="True" AllowSorting="True"
AutoGenerateColumns="False" DataSourceID="SqlDataSource2" PageSize="3">
<Columns>
<asp:BoundField DataField="id" HeaderText="id" InsertVisible="False" ReadOnly="True"
SortExpression="id" />
<asp:BoundField DataField="tid" HeaderText="tid" SortExpression="tid" />
<asp:BoundField DataField="name" HeaderText="name" SortExpression="name" />
</Columns>
</asp:GridView>
</ContentTemplate>
<Triggers>
<atlas:ControlValueTrigger ControlID="DropDownList1" PropertyName="id" />
</Triggers>
</atlas:UpdatePanel>
</form>
</body>
</html>