I am trying to display an image (byte array) using purely JavaScript.
How can I achieve this in ASP.NET?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you have the byte array, you first convert it to
Base64Stringand then you place it on animgtag like that (for a PNG image):Similar Stack Overflow questions:
Display bytes as images on an .aspx page
‘data:image/jpg;base64’ and jQuery image preview in Internet Explorer
Convert from binary data to an image control in ASP.NET