【解】
C# 保存
string fullpath =openFileDialog1.FileName;//文件路径 FileStream fs = new FileStream(fullpath, FileMode.Open); byte[] imagebytes =new byte[fs.Length]; BinaryReader br = new BinaryReader(fs);
imagebytes = br.ReadBytes(Convert.ToInt32(fs.Length)); //打开数据库
SqlConnection con = new
SqlCommand com = new SqlCommand("insert into tb_08 values(@ImageList)",con);
com.Parameters.Add("ImageList", SqlDbType.Image); com.Parameters["ImageList"].Value = imagebytes; com.ExecuteNonQuery(); con.Close();