摘要:
using (Conn = new SqlConnection(ConnectionString)) { Conn.Open();//打开数据库连接 string sqlstr = "select * from UserInfo2"; SqlCommand cmd = new SqlCommand(sqlstr, Conn); cmd.CommandType = CommandType.Text; SqlDataReader dr = cmd.ExecuteReader(Comman... 阅读全文
posted @ 2013-01-21 10:16
yellowshorts
阅读(116)
评论(0)
推荐(0)
摘要:
using (Conn = new SqlConnection(ConnectionString)) { //DataAdapter更新数据 Conn.Open();//打开数据库连接 string sqlstr = "select * from UserInfo2 where UserName = @UserName"; SqlDataAdapter da = new SqlDataAdapter(); SqlCommand updatecmd = new SqlCommand(s... 阅读全文
posted @ 2013-01-21 10:14
yellowshorts
阅读(257)
评论(0)
推荐(0)
摘要:
using (Conn = new SqlConnection(ConnectionString)) { //DataAdapter插入数据 Conn.Open();//打开数据库连接 string sqlstr = "select * from UserInfo2"; SqlDataAdapter da = new SqlDataAdapter(); SqlCommand insertcmd = new SqlCommand(sqlstr, Conn); S... 阅读全文
posted @ 2013-01-21 10:13
yellowshorts
阅读(466)
评论(0)
推荐(1)
摘要:
using (Conn = new SqlConnection(ConnectionString)) { //DataAdapter删除数据 Conn.Open();//打开数据库连接 string sqlstr = "select * from UserInfo2 where UserName = @UserName"; SqlDataAdapter da = new SqlDataAdapter(); SqlCommand deletecmd = new SqlCommand(s... 阅读全文
posted @ 2013-01-21 10:11
yellowshorts
阅读(169)
评论(0)
推荐(0)
摘要:
protected SqlConnection Conn; protected string ConnectionString = "server=.; database=ExpatiateAspNet; uid=sa; pwd="; protected void Page_Load(object sender, EventArgs e) { using (Conn = new SqlConnection(ConnectionString)) { Conn.Open();//打开数据库连接 SqlComma... 阅读全文
posted @ 2013-01-21 09:50
yellowshorts
阅读(211)
评论(0)
推荐(0)
摘要:
protected SqlConnection Conn; protected string ConnectionString = "server=.; database=ExpatiateAspNet; uid=sa; pwd="; protected void Page_Load(object sender, EventArgs e) { using (Conn = new SqlConnection(ConnectionString)) { Conn.Open();//打开数据库连接 SqlComma... 阅读全文
posted @ 2013-01-21 09:45
yellowshorts
阅读(583)
评论(0)
推荐(0)
摘要:
没有为扩展名“.html”注册的生成提供程序。可以在 machine.config 或 web.config 中的 <compilation><buildProviders> 节注册一个。请确保所注册的提供程序具有包含值“Web”或“All”的 BuildProviderAppliesToAttribute 属性。说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。解决方法:增加一项web.config配置节点(红色部分为需新增节点):<compilation defaultLanguage 阅读全文
posted @ 2013-01-21 09:22
yellowshorts
阅读(181)
评论(0)
推荐(0)

浙公网安备 33010602011771号