Shivaraj Poojary

Shivaraj Poojary

  • NA
  • 92
  • 314.4k

storing and retrieving image from database

Nov 21 2010 11:55 PM
Dear sir, i have the following code for storing images into database..i wanted to know how to retrieve the image from database...plz help me out regards thjis.
  byte[] data = null;
                FileInfo fi = new FileInfo(txtFile.Text);
                long numBytes = fi.Length;
                FileStream fstream = new FileStream(txtFile.Text, FileMode.Open, FileAccess.Read);
                BinaryReader br = new BinaryReader(fstream);
                data = br.ReadBytes((int)numBytes);


Answers (1)