If you compile your program with the target platform set to AnyCPU
then, when you run you executable on a 64bit OS the JIT compiler emits code for 64bit systems and, on 32bit OS, code for 32bit systems.
From your error it is clear that something between your references is a 32bit only library and thus cannot be called from 64bit code.
You could switch back to 32bit setting the x86
target platform in your Build Configuration
or try to identify the library responsible and check if a 64bit version exists.
However, if you don't have specific reasons to use AnyCPU
then you could still use x86
because in some cases the performances are better than 64bit code
You could read about the PROS and CONS of AnyCPU in this a little old, but still valuable, article