i have tried below code to get image on image control but when i double click image not getting and display like crack. what is wrong in this code. ?
i tried to display stored binary image from sql server to image control.
after double click on listbox control.
- string id = searchRecord.SelectedItem.Value;
- if (dt.Rows.Count > 0)
- {
- byte[] bytes = (byte[])dt.Rows[0]["V_IMAGE"];
- string base64String = Convert.ToBase64String(bytes, 0, bytes.Length);
- vImage.ImageUrl = "data:image/jpg;base64" + base64String;
-
- }