Include cpr library
How can I Include the cpr library into qt?
Hi and welcome to devnet,
If you are using cmake, you can follow cpr's documentation.
Just in case, you can also use the QNetworkAccessManager class from Qt for network requests.
I tried the documentation using vcpkg and it is working on visual studio normally, I just want a way to be able to link the the library to qt creator
What exactly did you try ?
What build system are you using ?
What compiler are you using with Qt ?
I used the cpr documentation and have the library installed by vcpkg, and the library works normally on visual studio, but for some reason whenever I QT Creator it is not able to find the library
@YoussofAttallah What exact Qt version do you use in QtCreator? With C++ libraries you have to use same compiler for the library and you app. For example you can't mix binaries built using VisualC++ and MinGW compiler.
Also note that Qt Creator gains some direct support for vcpkg only in the next upcoming release: https://www.qt.io/blog/qt-creator-cmake-package-manager-auto-setup