I am looking for the code if this is possible.. I have done this for an image. by first converting the image to a byte array like so :
public static Byte Image2Bytes(Image img)
Byte arr = new Byte;
using(MemoryStream ms = new MemoryStream())
arr = ms.ToArray();
using the above method i can convert an Image to binary but i need to convert other types to binary and these are our day-to-day commonly used files.