<%@ Page Language="C#" MasterPageFile="~/Template1.Master" AutoEventWireup="true" CodeBehind="TelCharge.aspx.cs" Inherits="WebApplication1.通讯录" Title="通讯录" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <style type="text/css">
        #juzhong { text-align:center; }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<body>
    <div id="juzhong">
        <table style="border: 1px none Black; width: 608px; height: 307px;">
        <tr>
        <td colspan="3" style="background-color:blue; font-weight:bold; text-align:center">通讯录管理</td>
        </tr>
            <tr>
                <td style="text-align: right; ">
                    请输入联系人姓名：
                </td>
                <td>
                    <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
                </td>
                <td align="right">
                    <asp:Button ID="Button1" runat="server" Text="查询" onclick="Button1_Click"/>
                </td>
            </tr>
            <tr>
                 <td colspan="3">
                 <asp:GridView ID="gvwTel" runat="server" Width="611px" AutoGenerateColumns="False" 
                         Height="70px" DataKeyNames="txname" onrowcommand="gvwTel_RowCommand" 
                         onrowdeleting="gvwTel_RowDeleting">
                     <Columns>
                         <asp:BoundField HeaderText="通讯组名称" DataField="txname" ReadOnly="True" 
                             SortExpression="txname" />
                         <asp:BoundField HeaderText="通讯组人员" DataField="txmember" 
                             SortExpression="txmember" />
                         <asp:BoundField HeaderText="适用部门" DataField="txuser" 
                             SortExpression="txuser" />
                         <asp:BoundField HeaderText="通讯组简介" DataField="txintro" 
                             SortExpression="txintro" />
                         <asp:TemplateField>
                          <ItemTemplate>
                             <asp:Button ID="btnUpt" runat="server" Text="修改" CommandName="Edit" CommandArgument='<%# Eval("txname")%>'/>
                             <asp:Button ID="btnDele" runat="server" Text="删除" CommandName="Delete" CommandArgument='<%# Eval("txname")%>'/>
                          </ItemTemplate>
                         </asp:TemplateField>
                     </Columns>
                     </asp:GridView>
                 </td>
            </tr>
            
            <tr>
                <td align="center" colspan="4">
                    <asp:Button ID="btnAdd" runat="server" Text="添加"  
                        style="height: 26px" onclick="btnAdd_Click" />
                </td>
            </tr>
        </table>
    </div>
</body>
</asp:Content>
