Je reçois l'octet dans la base de données mais je ne peux pas le convertir en bitmap, j'ai une exception dans le paramètre. C'est ce que j'ai fait jusqu'ici.Conversion d'octets en image bitmap
con.ConnectionString = MyConnectionString;
con.Open();
OdbcCommand cmds = new OdbcCommand("Select ID from try where kalabaw = 5", con);
OdbcDataAdapter da = new OdbcDataAdapter(cmds);
byte[] image = (byte[])cmds.ExecuteScalar();
TypeConverter tc = TypeDescriptor.GetConverter(typeof(Bitmap));
Bitmap bitmap = (Bitmap)tc.ConvertFrom(image);
pictureBox2.Image = bitmap;
con.Close();
http://stackoverflow.com/questions/14337071/convert-array-of-bytes-to-bitmapimage –
je ne peux pas passer la executeSalar à la méthode – shampoo
il n'y a pas ExecuteScalar dans le lien que je vous ai envoyé –