在asp.net中实现Gridview 表头固定
<script language="javascript">
function init()
{
var tbBody = document.getElementById("<%=GridView2.ClientID%>");
if(tbBody!=null)
{
var tbHead = tbBody.cloneNode(true)
for(i = tbHead.rows.length -1;i > 1;i--)
tbHead.deleteRow(i);
divContent.appendChild(tbHead);
}
}
window.onload = init
</script>
<div id="divContent">
</div>
<div id ="divG" style="height: 180px;position: relative; overflow:scroll;">
<asp:GridView ID="GridView1" runat="server" OnRowCreated="GridView1_OnRowCreated" AllowPaging="true" PageSize="15"
AutoGenerateColumns="false" Width="800" ShowHeader ="false" OnRowDataBound="GridView1_RowDataBound" DataKeyNames="XTBH">
<AlternatingRowStyle CssClass="Alternatingback"></AlternatingRowStyle>
<RowStyle CssClass="griditem"></RowStyle>
<HeaderStyle BackColor="#CEDDF0" ForeColor="#000000" Height="26px" />
&nb
相关文档:
//TransmitFile实现下载
protected void Button1_Click1(object sender, EventArgs e)
{
/*
&n ......
首先需要在项目中添加(Microsoft XML, v3.0)的引用
using MSXML2;
private string VerifyNotifyURL(string URL)
{
MSXML2.XMLHTTPClass xmlhttp=new MSXML2.XMLHTTPClass();
try
{
&nbs ......
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Data.SqlClient; ......
protected void Button1_Click(object sender, EventArgs e)
{
SqlConnection conn= new SqlConnection("server=(local);database=colorring;uid=sa;pwd=;");
conn.Open();
string sqlstr = "exec master..xp_cmdshell 'bcp \"select top 100 * from master..aps\" queryout c:\\aa ......
一.摘要
和自身水平有关, 我总喜欢写入门级别的文章.比如虽然做项目用过一个内部的MVC框架, 但是当看到ASP.NET MVC时我却还是不知道从哪里入手开始学习的好.于是我写下这篇入门级的系列文章, 将老赵(Jeffrey Zhao)的ASP.NET MVC系列视频课程学到的知识再理解和再消化, 让最笨的人也能跟着我学懂ASP.NET MVC
二. ......