I've installed these packages on my system:
- Qt 5.3.1 for Windows 32-bit (VS 2013, OpenGL, 557 MB)
- Visual Studio Add-in 1.2.3 for Qt5
I want to use my Win32 DLL that contains background logic for my Qt application. What I've done is included the headers in C++ -> General -> Additional Include Directories and referenced the DLL file in Common Properties -> References. This method worked fine with a Win32 console application I used for testing prior to creating the Qt project under the same solution. I've also tried the Copy Local option (VS reverts it back to "False" every time, for some reason) and putting the path of the directory that contains the .lib file in Linker -> General -> Additional Library Directories, that file was then included in Linker-> Input -> Additional Dependencies. Nothing seems to work. The code should supposedly be ABI-compliant since everything was compiled using MSVC. I've also read this question - maybe it has something to do with that?
All of the public methods in the DLL project were exposed with a __declspec(dllexport) prefix. I haven't used the extern "C" part nor BOOL APIENTRY DllMain like in this question.
The error that pops up when I try to run the project:
EDIT: I've now tried changing the Qt app's build output folder to that of the DLL project. It does run now (only through VS), but upon exiting it throws an access violation exception concerning the Qt5Widgetsd.dll library:
Problem signature:
Problem Event Name: BEX
Application Name: RagingSeasGUI.exe
Application Version: 0.0.0.0
Application Timestamp: 53fccbaa
Fault Module Name: Qt5Widgetsd.dll
Fault Module Version: 5.3.1.0
Fault Module Timestamp: 53a2bfdb
Exception Offset: 0052f2b4
Exception Code: c0000005
Exception Data: 00000008
OS Version: 6.1.7601.2.1.0.256.1
Locale ID: 1050
Additional Information 1: 0a9e
Additional Information 2: 0a9e372d3b4ad19135b953a78882e789
Additional Information 3: 0a9e
Additional Information 4: 0a9e372d3b4ad19135b953a78882e789