How do I load Image that is Byte[] that I get from the DB to the client side?

Hello, I got a problem and I didn’t find the answer with Google, maybe I’m not looking perfect

Well the following is the thing, I receive through the DAL a var that may be Byte that features an image(jpg for example) And now I want to be able to convert it for you to an image and show it about my client side page.
How to do that

Thanks for the help.

p. vertisements I develop within asp. net

Here’s how i would do the item in C#. web and VB. web.

Thought process you, storing images within a database generally isn’t the most effective way to go related to doing things. The extra overhead created by having to retrieve an entire image and diplay this vs. generating an image tag determined by a file inside filesystem alone causes it to be worth storing images in the file system.

http: //databases. aspfaq. com/database/should-i-store-images-in-the-database-or-the-filesystem. html

If you possibly could just store a reference on the file in the particular database (along along with image dimensions… your page a lot will decrease a great deal if you might call the image dimensions from DB) vs. the image by itself, you’ll probably be a whole lot better off. I’ve never had a great time storing images in database, consequently I don’t even bother.

Thank you I’ll keep it as the primary goal but in cases like this my data has to be encrypted, can’t give much more info about it, images must be encrypted too, and I wasn’t the one that decided on this kind of projects design
Anyway is at this time there any chance this somebody have an Idea how to do it work in the DB.

This entry was posted in Web Design and tagged , , , , , , , , , , , , , , , , . Bookmark the permalink.

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *