C#连接SQL2000的代码
C#连接SQL2000的代码能不能给我?
NameValueCollection values = (NameValueCollection)ConfigurationSettings.GetConfig( "appParams" );
string strconn = values["connectionString"];
SqlConnection cn=new SqlConnection(strconn);
cn.Open();
string strsql="select * from Operator where OperatorID='" +Use.Text+"' and Password='"+Usepwd.Text+"'";
SqlCommand cm=new SqlCommand(strsql,cn);
SqlDataReader dr=cm.ExecuteReader();