tags:

views:

28

answers:

2

Hello,

I have pictures of each employee stored in SQL database with Image database.

Select pic from empimages where emp_ID=10

give the picture of that employee in binary format.

How do I create a physical jpeg in C:\images folder based on the above query in vb.net.

Thanks

+1  A: 

In what format do you have the file? As a byte array? In that case, simply write

My.Computer.FileSystem.WriteAllBytes( _
    "C:\images\" & imagename & ".jpg", ImageData, False)
Konrad Rudolph
A: 

Here is a good tutorial relating to this: Creating Binary Files using Visual Basic

You should be able to just take the data from the blob and write it to a file this way. Hope it helps.

Jeremy Morgan