System.IO.File.ReadAllBytes(string filePath); //The other way around: System.IO.File.WriteAllBytes(string filePath, byte[] sourceBytes);
Friday, October 28, 2011
Convert an Image to byte array in one line
Here's an easy way to convert any file on disk to a byte array
Tuesday, April 19, 2011
System.BadImageFormatException on a 64-bit machine
So you've used a Visual Studio Installer to build and deploy an application. You try to run in after you install the application and all that you get is a System.BadImageFormatException - what have you done wrong!!
Well turns out that you have to define what platform you are building the application for when you run the build (x86 or x64). You can specify this on the project properties under the build tab - PlatformTarget.
Well turns out that you have to define what platform you are building the application for when you run the build (x86 or x64). You can specify this on the project properties under the build tab - PlatformTarget.
Subscribe to:
Posts (Atom)