Select to view content in your preferred language

10.2.6 Installation Issue

4944
9
Jump to solution
06-22-2015 01:54 PM
AndyWright
Frequent Contributor

I just installed the latest version of the QML API and am getting an error when trying to run a basic template app.  I did some Googling on this issue and in the past it has been related to running Qt 5.4 against the API rather than 5.4.1.  I am definitely running 5.4.1 and I am on a Windows 7 64-bit laptop.  I've been running this architecture against the 10.2.5 API successfully for months, so I'm not sure what happened.  Any ideas?

Starting C:\Temp\build-untitled-Desktop_Qt_5_4_1_MSVC2013_OpenGL_64bit-Debug\debug\untitled.exe...

QML debugging is enabled. Only use this in a safe environment.

Initializing application

QQmlApplicationEngine failed to load component

qrc:/qml/main.qml:16 plugin cannot be loaded for module "ArcGIS.Runtime": Cannot load library C:/Qt/Qt5.4.1_Windows/5.4/msvc2013_64_opengl/qml/ArcGIS/Runtime.10.26/ArcGISRuntimePlugind.dll: The specified module could not be found.

int __cdecl main(int,char *[]) QObject(0x0)

Error: Your root item has to be a Window.

C:\Temp\build-untitled-Desktop_Qt_5_4_1_MSVC2013_OpenGL_64bit-Debug\debug\untitled.exe exited with code -1

0 Kudos
1 Solution

Accepted Solutions
LucasDanzinger
Esri Frequent Contributor

Hey Robert-

You need to install the non OpenGL Windows Qt Kit. Notice that in the path in your error message, it says "msvc2013_64_opengl". You want to install the one that just says "msvc2013_64". This one should do the trick - http://download.qt.io/official_releases/qt/5.4/5.4.2/qt-opensource-windows-x86-msvc2013_64-5.4.2.exe

Qt releases a few different versions of their Windows kit - one is built to use OpenGL for graphics display, and the other is used to use ANGLE. Our 10.2.5 release used OpenGL, but moving forward (10.2.6 onward), we will be building our Windows libs using ANGLE. More info about what this means can be found here - ArcGIS Runtime SDK for Qt: Migrating 10.2.5 Windows apps to 10.2.6 and DirectX | ArcGIS Blog

Let me know how it goes.

-Luke

View solution in original post

0 Kudos
9 Replies
LucasDanzinger
Esri Frequent Contributor

Andy-

Please see the Migrating Existing Apps section in the 10.2.6 release notes - Release notes for ArcGIS Runtime SDK 10.2.6 for Qt—ArcGIS Runtime SDK for Qt | ArcGIS for Developers

You need to install a different Qt Kit with 10.2.6, as we build our libraries using ANGLE instead of OpenGL. You will also need to add a few lines to the main cpp and the .pro file (the specifics are in the release notes).

Hope this helps!

-Luke

0 Kudos
AndyWright
Frequent Contributor

Yeh I got the new code added to the main.cpp, but didn't realize the new kit was a hard requirement.  I'll give that a shot.  Thanks Luke ...

0 Kudos
RobertLawrence
Deactivated User

I have this same exact problem. I already had the "QCoreApplication::setAttribute(Qt::AA_UseOpenGLES);" statement in my main.cpp as instructed and I still get the same problem.

I hope Andy figures it out and replies back because I may have to switch to Visual Studio. I really prefer Qt though.

0 Kudos
RobertLawrence
Deactivated User

Luke,

I have followed everything in the instructions and release notes and I am still getting this error. I have the correct version of Qt, I downloaded everything in the order given. Is this easier with 10.2.5?

Where can I get  the  ArcGIS Runtime SDK for Qt 10.2.5 release? I really need to get something working. I cannot get past this error when I build with 10.2.6

qrc:/qml/main.qml:16 plugin cannot be loaded for module "ArcGIS.Runtime": Cannot load library C:/Qt/Qt5.4.2/5.4/msvc2013_64_opengl/qml/ArcGIS/Runtime.10.26/ArcGISRuntimePlugind.dll:

0 Kudos
LucasDanzinger
Esri Frequent Contributor

Hey Robert-

You need to install the non OpenGL Windows Qt Kit. Notice that in the path in your error message, it says "msvc2013_64_opengl". You want to install the one that just says "msvc2013_64". This one should do the trick - http://download.qt.io/official_releases/qt/5.4/5.4.2/qt-opensource-windows-x86-msvc2013_64-5.4.2.exe

Qt releases a few different versions of their Windows kit - one is built to use OpenGL for graphics display, and the other is used to use ANGLE. Our 10.2.5 release used OpenGL, but moving forward (10.2.6 onward), we will be building our Windows libs using ANGLE. More info about what this means can be found here - ArcGIS Runtime SDK for Qt: Migrating 10.2.5 Windows apps to 10.2.6 and DirectX | ArcGIS Blog

Let me know how it goes.

-Luke

0 Kudos
RobertLawrence
Deactivated User

Thanks Lucas. I downloaded the msvc2013_64_opengl version of Qt and that fixed my problem.

Thanks again !

0 Kudos
CeyhunYilmaz
Occasional Contributor

Hi Andy,

I think link where below will helps you.

Problem with MyFirstMap example (MSVC2013 + QML)

0 Kudos
AndyWright
Frequent Contributor

That's not my issue Ceyhun, but thanks for posting that.  I am definitely using 5.4.1.  Unfortunately I got pulled off on to some other work right after I started the upgrade, so I haven't gotten the chance to pursue Luke's suggestion.  I already had the code in main.cpp, but haven't grabbed the new kit yet.  The little bit of poking around I did lead me to this page which has a link to ANGLE stuff there, but I didn't see anything about a Qt kit.  Again, I didn't get to spend too much time digging around yet though.

Qt for Windows - Requirements | Qt 5.4

0 Kudos
AndyWright
Frequent Contributor

I finally got around to doing this upgrade and I had to do one more thing to my 10.2.5 project to get it to work in 10.2.6.  There is a line of code in the .pro file that looked like this in 10.2.5:

CONFIG += c++11 arcgis_runtime_qml

I was still getting the original error even though I had the correct Windows ANGLE kit.  Everything started working properly once I modified that line in the .pro file to this:

CONFIG += c++11 arcgis_runtime_qml10_2_6

Doesn't look like anyone else in this thread had the same problem, but I figured I'd post anyway for others who may hit this.  Thanks for pointing us in the right direction on that kit Luke ...

0 Kudos