I would like to use GoogleMap with QWebEngineView. It works fine in Windows 7 (my computer of developpement), but it crashes directly in windows 10 with the following error message :
"Faulting application name: Google-map.exe, version: 0.0.0.0, time stamp: 0x5d5d1607 Faulting module name: Qt5Core.dll, version: 5.12.2.0, time stamp: 0x5c815eff Exception code: 0xc0000409 Fault offset: 0x0000000000028808 Faulting process id: 0x1c70 Faulting application start time: 0x01d5582d71146bed Faulting application path: C:\Google-map\Google-map.exe Faulting module path: C:\Google-map\Google-map\Qt5Core.dll Report Id: 5222fc86-9fac-41ab-b152-27e0f826f50d Faulting package full name: Faulting package-relative application ID:"
I tested with Qt5.12.2 MSVC2017-64bits and Qt5.13.0 MSVC2017-64bits
my main.cpp
#include "mainwindow.h"
#include <QApplication>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
MainWindow w;
w.show();
return a.exec();
}
my mainwindow.cpp
#include "mainwindow.h"
#include "ui_mainwindow.h"
#include <QtWebEngineWidgets/QWebEngineView>
#include <QtWebEngineWidgets/QWebEnginePage>
#include <QtWebEngineWidgets/QWebEngineSettings>
MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::MainWindow)
{
ui->setupUi(this);
QWebEngineView* webview = new QWebEngineView;
QUrl url = QUrl("qrc:/map.html");
webview->page()->load(url);
ui->verticalLayout->addWidget(webview);
}
MainWindow::~MainWindow()
{
delete ui;
}
My full project can be found here : https://github.com/hunglxtp/googlemapqtwebenginwindow10crash
Anyone has the same issue ? Thank a lot.
User contributions licensed under CC BY-SA 3.0