在做成绩录入系统时,想让各个数据表里的信息显示在dataGridView2中,结果出现“至少一个参数没有指定值”错误提示。。。。。求帮助,看看哪里有问题
在做成绩录入系统时,想让各个数据表里的信息显示在dataGridView2中,结果出现“至少一个参数没有指定值”错误提示。。。。。求帮助,看看哪里有问题private void button3_Click(object sender, EventArgs e)
{
OleDbConnection conn = new OleDbConnection();
conn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data source=jiaowu.mdb";
conn.Open();
DataTable dt = new DataTable();
dt.Clear();
string Cmd = "select a.课程编号,b.课程名称,a.学号,c.姓名,a.成绩 from chengjibiao a,kechengxinxi b,xueshengxinxi c "
+ "where(a.课程编号=b.课程编号)and(a.学号=c.学号)and(b.教师编号='" + UserInfo.Pwd + "')";
OleDbCommand command = new OleDbCommand(Cmd, conn);
OleDbDataAdapter da = new OleDbDataAdapter();
da.SelectCommand = command;
dt.Clear();
OleDbDataAdapter AdapterSelect = new OleDbDataAdapter("select a.编号,a.课程编号,b.课程名称,a.学号,c.姓名,a.成绩 from chengjibiao a,kechengxinxi b,xueshengxinxi c "
+ "where(a.课程编号=b.课程编号)and(a.学号=c.学号)and(b.教师编号='" + UserInfo.Pwd + "')", conn);
AdapterSelect.Fill(dt);
dataGridView2.DataSource = dt.DefaultView;
} DataGridView command
补充:云计算 , 云安全