日期:2014-05-17 浏览次数:20710 次
cmd.CommandText = sql;//sql语句
SqlDataReader dr = cmd.ExecuteReader();
BindingSource bs = new BindingSource();
bs.DataSource = dr;
this.dataGridView3.DataSource = bs;
DataGridViewImageColumn column = new DataGridViewImageColumn();
dataGridView3.Columns.Add(column);
column.HeaderText = "图片";
DataGridView3["Image", 0].Value = new Bitmap("图片路径");