' 給RptDoc 指定數據, CrystalView1.ReportSource = RptDoc '給CrystalView指定數據 CrystalView1.DataBind() conn.Close() 5.如果需要顯示的為多表關聯的字段,最好以存儲過程建立DataSet --------------------------------------------------------------- 请参考如下代码: string strconn=连接串; SqlConnection myconn=new SqlConnection(strconn); string strcmd=@"select语句"; SqlCommand mycmd=new SqlCommand(strcmd,myconn); SqlDataAdapter myda=new SqlDataAdapter(strcmd,myconn); DataSet myds=new DataSet();
上一篇:在 ASP.NET 中用匿名委托简单模拟 AOP 做异常和日志处理
下一篇:存储过程使用技巧
|