- 博客(4)
- 资源 (2)
- 收藏
- 关注
转载 关于ExecuteReader()获得参数值和返回值的方法
在ADO.NET里面,我往往是通过ExecuteReader()得到SqlDataReader,然后再将其邦定到Reapter控件中,这样以最高效率读取数据,并高效邦定数据。在最开始使用SQL2005进行开发时,就遇到过这样一个问题:在邦定控件前需要读出数据总量,而使用SqlDataCommand的ExecuteReader方法并没有获得参数值和返回值得方法。具体代码可以参考如下:假如我们
2014-06-02 10:37:22 6468
原创 常用的数据库公共类
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Data.SqlClient;using System.Windows.Forms;using System.Data;using System.IO;using System.
2014-06-02 10:29:27 979
原创 遍历控件代码和常用的MessageBox提示
foreach (Control C in groupBox3.Controls) { if ((C is TextBox) && C.Text == "") { MessageBox.Show("请填写文本框" + C.Name);
2014-06-02 10:20:36 456
原创 ExecuteNonQuery与ExecuteScalar的区别
public int GetRsCount(string table_name) { string strSql; int intCount; Open(); strSql="select count(*) from "+table_name; SqlCommand cmd=new SqlCommand(strSql,cn); 语句1) intC
2014-06-02 09:45:28 2163
JDBC 4.0 For SqlSever[含帮助文档]
2015-12-27
mvc自定义分页封装
2015-11-10
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人