SHARE
TWEET

Untitled

a guest Jun 19th, 2019 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using (conn = new OleDbConnection(connectionstring))
  2.             {
  3.                 using (cmd = new OleDbCommand("SELECT PICTURE FROM HomeBased WHERE ID = @id", conn))
  4.                 {
  5.                     cmd.Parameters.AddWithValue("@id", listers.SelectedValue);
  6.                     conn.Open();
  7.                     byte[] bytes = (byte[])cmd.ExecuteScalar();
  8.                     conn.Close();
  9.                     picmid.BackgroundImage = Image.FromStream(new MemoryStream(bytes));
  10.                 }
  11.             }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top