Given the file path (for example, "C: \ MyPicture.jpg"), how do I convert the binary to an array of bytes?
I know what I have in my possession a lot of .NET objects, such as BinaryReader, FileStream, StreamReaderand others, but I'm not sure what the best way to take a binary file and convert it to byte[]. How can I do that?
source
share