• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

c#大圣之路笔记——c#DataGridcheckbox操作

原作者: [db:作者] 来自: [db:来源] 收藏 邀请
  1 ///html
  2 
  3 <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="xOEMStoreNominationForCAM.aspx.cs" EnableEventValidation="false" Inherits="PRCSales_external.Store.xOEMStoreNominationForCAM" %>
  4 
  5 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  6 
  7 <html xmlns="http://www.w3.org/1999/xhtml">
  8 <head runat="server">
  9     <title>xOEM Store Nomination for CAM</title>
 10     <link href="../css/main.css" rel="stylesheet" type="text/css" />
 11     <link href="../css/Styles_1.css" rel="stylesheet" type="text/css" />
 12     
 13     <script type="text/javascript" src="../js/jquery-1.8.2.js"></script>
 14     <script type="text/javascript" src="../js/LocationFilterQuarter.js"></script>
 15 
 16     <script type="text/javascript">
 17 
 18 
 19             function CheckAll(chkObject) {
 20                 var checkArray = document.getElementsByTagName("input");
 21                 for (j = 0; j < checkArray.length; j++) {
 22                     if (checkArray[j].type == "checkbox" & checkArray[j] != chkObject ) {
 23                         if (chkObject.checked != checkArray[j].checked)
 24                             checkArray[j].checked = chkObject.checked;
 25                     }
 26                 }
 27             }
 28 
 29          
 30 
 31 
 32             function ShowWaiting() {
 33                 document.getElementById('doing').style.visibility = 'visible';
 34             }
 35             function CloseWaiting() {
 36                 document.getElementById('doing').style.visibility = 'hidden';
 37             }
 38             function MyOnload() {
 39                 document.getElementById('doing').style.visibility = 'hidden';
 40             }
 41 
 42             if (window.onload == null) {
 43                 window.onload = MyOnload;
 44             }
 45 
 46     </script>
 47 
 48 
 49     <style type="text/css">
 50             #btnMark ,#btnUnmark
 51             {
 52                 margin-left:5px;
 53             }
 54     
 55     </style>
 56 
 57 
 58 </head>
 59 <body>
 60     <form id="form1" runat="server"> 
 61     <table width="100%" id="Table1">
 62         <tr ><td style="height:30px; "><b>xOEM Store Nomination for CAM</b></td></tr>
 63         <tr>
 64          <tr style="HEIGHT: 1px; BACKGROUND-COLOR: #3366ff">
 65                     <td colSpan="4"><FONT style="BACKGROUND-COLOR: #ffffff" face="宋体"></FONT><FONT face="宋体"></FONT></td>
 66                 </tr>
 67         <tr>
 68                 <td class="fieldtitle" width="30%">Quarter:</td>
 69                 <td class="fieldtitle" width="20%"><asp:dropdownlist id="ddlQuarter" runat="server"  AutoPostBack="true"
 70                         onselectedindexchanged="ddlQuarter_SelectedIndexChanged"  onchange="initData('region')"></asp:dropdownlist></td>
 71                 <td class="fieldtitle" width="20%">
 72                     Region/Grid/City:
 73                 </td>
 74                 <td class="fieldtitle" colspan="3" width="30%">
 75                     <asp:DropDownList ID="ddlRegion" runat="server" CssClass="fieldList" onchange="initData('subregion')">
 76                     </asp:DropDownList>
 77                     <asp:DropDownList ID="ddlSubRegion" runat="server" CssClass="fieldList" style="display:none;" onchange="initData('grid')">
 78                     </asp:DropDownList>
 79                     <asp:DropDownList ID="ddlGrid" runat="server" CssClass="fieldList"  onchange="initData('pref')">
 80                     </asp:DropDownList>
 81                     <asp:DropDownList ID="ddlPref" runat="server" CssClass="fieldList" style="display:none;"  onchange="initData('city')">
 82                     </asp:DropDownList>
 83                     <asp:DropDownList ID="ddlCity" runat="server" CssClass="fieldList"  onchange="initData('county')">
 84                     </asp:DropDownList>
 85                     <asp:DropDownList ID="ddlCounty" runat="server" CssClass="fieldList" style="display:none;" onchange="initData('town')">
 86                     </asp:DropDownList>
 87                     <asp:DropDownList ID="ddlTown" runat="server" CssClass="fieldList" style="display:none;" onchange="initData('village')">
 88                     </asp:DropDownList>
 89                     <asp:DropDownList ID="ddlVillage" runat="server" CssClass="fieldList" style="display:none;" onchange="initData('village1')">
 90                     </asp:DropDownList>
 91                         
 92                     <asp:TextBox ID="txtWWID" runat="server" Style="display: none"></asp:TextBox>
 93                     <asp:TextBox ID="txtQuarter" runat="server" Style="display: none"></asp:TextBox>
 94                     <asp:TextBox ID="txtRegion" runat="server" Style="display: none"></asp:TextBox>
 95                     <asp:TextBox ID="txtSubRegion" runat="server" Style="display: none"></asp:TextBox>
 96                     <asp:TextBox ID="txtGrid" runat="server" Style="display: none"></asp:TextBox>
 97                     <asp:TextBox ID="txtPref" runat="server" Style="display: none"></asp:TextBox>
 98                     <asp:TextBox ID="txtCity" runat="server" Style="display: none"></asp:TextBox>
 99                     <asp:TextBox ID="txtCounty" runat="server" Style="display: none"></asp:TextBox>
100                     <asp:TextBox ID="txtTown" runat="server" Style="display: none"></asp:TextBox>
101                     <asp:TextBox ID="txtVillage" runat="server" Style="display: none"></asp:TextBox>
102                 </td>
103 
104         </tr>
105         <tr>
106             <td class="fieldtitle" width="30%" >Store Name:</td>
107             <td class="fieldtitle" width="20%" colspan="1"><asp:TextBox ID="txtStorNm" runat="server"></asp:TextBox></td>
108             <td class="fieldtitle" width="20%" >Store ID:</td>
109             <td class="fieldtitle" width="30%"><asp:TextBox ID="txtStorID" runat="server"></asp:TextBox></td>
110         </tr>
111        <%-- <tr>
112             <td  class="fieldtitle" width="20%" colspan=""><asp:CheckBox ID="chkStore"  runat="server" CssClass="fieldtitle" Text="Show Unassigned Store Only"/></td>
113         </tr>--%>
114         <tr style="HEIGHT: 1px; BACKGROUND-COLOR: #3366ff">
115                     <td colSpan="4"><FONT style="BACKGROUND-COLOR: #ffffff" face="宋体"></FONT><FONT face="宋体"></FONT></td>
116                 </tr>
117         <tr>
118             <td class="fieldtitle" width="30%" colspan="1">Store list <asp:Label ID="lblCount" runat="server" CssClass="fieldList"></asp:Label>
119               <%-- <asp:Label ID="lblMessage" runat="server" CssClass="fieldList" ForeColor="Red" Text="季度店面标记"></asp:Label>  --%>
120                     <asp:Label ID="lblLeftTime" CssClass="fieldList" runat="server" ForeColor="Red"></asp:Label>  
121             </td>
122              
123             <td align="right" colspan="3" width="70%">
124             <asp:Button ID="btnSearch" runat="server" Text="Search"   CssClass="fieldButton" onclick="btnSearch_Click"  Width="80px"/> 
125             <asp:Button ID="btnMark" runat="server" Text="Mark"   CssClass="fieldButton" onclick="btnMark_Click" Width="80px" />
126             <asp:Button ID="btnUnmark" runat="server" Text="Unmark" CssClass="fieldButton"   onclick="btnUnmark_Click" Width="80px" />
127             </td>
128         </tr>
129         <tr>
130             <td colspan="4">
131                 <asp:DataGrid ID="GridMain" runat="server" Width="100%" 
132                     AutoGenerateColumns="false" PageSize="20" AllowPaging="true" 
133                      onselectedindexchanged="GridMain_SelectedIndexChanged"  onpageindexchanged="GridMain_PageIndexChanged">
134                 <AlternatingItemStyle CssClass="datagridAlternating" />
135                 <HeaderStyle CssClass="tableHead" />
136                 <Columns>
137                     <asp:TemplateColumn>
138                    <HeaderStyle Width="20px"></HeaderStyle>
139                      <HeaderTemplate><asp:CheckBox ID ="checkAl 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C#中this关键字四种用法发布时间:2022-07-10
下一篇:
C#中部分方法返回值类型为什么只能是void?发布时间:2022-07-10
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap