How To Use Dll Files in Program
-
hi
please read
http://doc.qt.io/qt-5/third-party-libraries.htmlYou can also open the .pro file and right click.
This opens a dialog where you can input the info.Please note that not all DLLS can just be used with any compiler if not a plain c dll.
So if you are using Mingw compiler and the dlls are compiled with VS compiler, it might not work. -
@M4RZB4Ni
oh. not sure it can work.
maybe with Visual Studio but surely not with mingw compiler.
https://social.msdn.microsoft.com/Forums/vstudio/en-US/440aca96-288a-4d5c-ab9a-87ea2cdd5ca8/how-to-call-c-dll-from-c?forum=csharpgeneralIts not trivial though.
-
Ignoring the Qt specific aspects of integrating a 3rd party library for just a moment, I would like to ask - are you implicitly or explicitly linking these DLLs into your application?
Implicitly linking means (in case you don't know) means your code links with a *.lib that makes yours application need the DLL in order to run but also means you don't have to locate the functions you want to use in the DLL when your code runs. This is most likely the way you plan to use these DLLs.
Explicitly linking means you don't do anything with the DLL until your application starts up - at that point your application code manually loads the DLL into its process space and your application code looks up the actual functions you want to use in the DLL. This is a very flexible way to use DLLs but you're probably not doing this.