http://cncode.com/SoftView.Asp?SoftID=116我的流言本源码 里边有分页的方法和你类似 .
解决方案 »
- history.go(-2)和load
- 多列放在同一个下拉框中
- 从服务器得到值,像iframe中传值的问题!
- ASP.NET使用webrequset抓取需要登陆以及验证码才能访问的页面
- datagrid 中的删除问题
- ASP.net 上传巨大文件
- asp.net不能上传大于4M的文件,来看看
- 我用asp.net做论坛,请问用xml来保存网友的发言好还是用sql来保存好,为什么?大侠们帮我啊
- 请那个大侠给我一个在线编辑器(最好有源程序)
- 好几天都没弄出来,MVC中 自定义IModelBinder问题
- 请问思归一个关于HttpContext.Current.Items和Cache的问题。
- 删除新闻分类时出现如下错误,请各位帮我看看!先谢谢了!100分!
http://www.mastercsharp.com/article.aspx?ArticleID=76&&TopicID=2
DataRepeater/DataList控件,我没有看看我的private void dataShow()
{
int StartIndex = CurrentPage*PageSize;
string sqlStr="select * from tblSoftInfo order by iId Desc,soft_DownTime Desc";
SqlDataAdapter da=new SqlDataAdapter(sqlStr,Conn);
DataSet ds=new DataSet();
da.Fill(ds,StartIndex,PageSize,"softInfo");
Conn.Close();
for(int i=0;i<ds.Tables["softInfo"].Rows.Count;i++)
{
TableRow r = new TableRow(); //新增行
r.Height=20;
TableCell c = new TableCell(); //新列
c.Height=20;
c.Width=400;
c.Controls.Add(new LiteralControl(" "+ds.Tables["softInfo"].Rows[i]["iId"].ToString()+".<a href='softInfo.aspx?id="+ds.Tables["softInfo"].Rows[i]["iId"].ToString()+"');>"+ds.Tables["softInfo"].Rows[i]["soft_Name"].ToString()+"</a> "));
r.Cells.Add(c);
TableCell c1 = new TableCell(); //新列
c1.Height=20;
c1.Width=100;
c1.Controls.Add(new LiteralControl("["+Convert.ToDateTime(ds.Tables["softInfo"].Rows[i]["soft_Date"].ToString()).ToString("yyyy-MM-dd")+"]"));
r.Cells.Add(c1);
Table1.Rows.Add(r);
}
}
if (!IsPostBack)
{}