I ended up here after a Google search. But I didn't find my answer here.
Instead, in my publish profile I needed to choose the x64 configuration. And when I did it worked.