I've just had this issue and it turned out that it was because I was referencing a previous version of the DLL from my UI project. Therefore, when compiling it was happy. But when running it was using the previous version of the DLL.
Check references on all other projects before assuming you need to rebuild/clean/redeploy your solutions.