Incorporating NLog into a native C++ VS 2005 application

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Incorporating NLog into a native C++ VS 2005 application

deyoungkr
I have a native C++ application that was developed a LONG time ago using Visual Studio 2005 and now would like to incorporate NLog into the existing application.

I have added the NLogC.h and NLogger.h include files to the application along with adding NLogC.lib into my linker dependencies. The application builds/links fine at this point.  If I add any function call from the list of those available in NLogC.dll to the application it fails to load when it is run.

I'm assuming this is due to the NLogC.dll being loaded because of adding a call to one of its functions. The exact error text I receive is:
"The application failed to initialize properly (0xc0000005). Click on OK to terminate the application"

Simply commenting out the call to the function enables the application to load and run normally.

Has anyone run into this or have a suggestion on how to remedy the problem?