Trouble loading CPlusPlusCHOPExample.dll (RESOLVED)

Hi all,

I’m trying to learn how to program a CPlusPlus CHOP, and I figured the best place to start would naturally be through the Wiki entry called “Write a CPlusPlus DLL”. I found the sample files in Touch’s subdirectories. I made a copy of the “CHOP” folder on my Desktop and opened the project in Visual Studio Express 2012. After successfully updating the project, I read through the files and got a good idea of how everything is structured. I made a build of the project and tried loading the DLL into a CPlusPlus CHOP, and this is where things went awry.

All I get is: “Error: Failed to load the .dll (/project1/cplusplus1)”.

Can anyone give me a hint as to what I’m doing wrong? I didn’t change any of the code at all…

Thanks,
Los

Are you using 088 64bit or 077? 64-bit 088 requires a 64-bit .dll, which you need a non-free version of 2012 for, I think. (Edit: I have since found this to be incorrect. VS2012 includes 64-bit compiler support)

Ahh, I’m using 088. I tried it in 077 and it worked. You’re the man, Malcolm. Thanks.

If you use 32-bit 088 you should be good.

OK cool. Would you happen to know which version of Visual Studio 2012 I’d need to write a 64 bit .dll?

I may be wrong actually, past Express versions didn’t include 64-bit, but I think 2012 may. You may want to take a closer look at at your build setting/Configuration Manager and see if you can add a 64-bit profile.

Malcolm, you’re absolutely right. I was able to change my built setting from Win32 to x64 in the Configuration Manager, and the .dll runs in 64-bit 088 with no problems.

Thanks again!