Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-26 Thread Elias Steurer via Development
I launch the qml app with these arguments (via VSCode launch.json):     "args": ["-I", "C:\\Code\\cpp\\build_Hello_Debug","-f", "C:\\Code\\cpp\\qml-plugin-minimal\\Main.qml", ], * My example project contains a simple Main.qml. with my Hello QML_ELEMENT o "C:\Code\cpp\qml-plugin-m

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-26 Thread Ulf Hermann via Development
I can confirm a simple:     for (const QString &importPath : parser.values(importOption)){     QByteArray path = qgetenv("PATH");     QByteArray newPath = importPath.toLocal8Bit() + ";";     newPath += path;     qputenv("PATH", newPath);     qDebug() << "Modified PATH:"

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-26 Thread Elias Steurer via Development
I can confirm a simple:     for (const QString &importPath : parser.values(importOption)){     QByteArray path = qgetenv("PATH");     QByteArray newPath = importPath.toLocal8Bit() + ";";     newPath += path;     qputenv("PATH", newPath);     qDebug() << "Modified PATH:" << qge

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-25 Thread Ulf Hermann via Development
Adding a command line option to add dll search paths via _wpuntenv_s(L"PATH", ...) or SetDLLDirectory(L"...") into qml.exe would also work, right? I didn't know this exists. You'd have to add a lot of directories, though, since it doesn't want to see the QML import path but the paths to the i

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-25 Thread Elias Steurer via Development
Adding a command line option to add dll search paths via _wpuntenv_s(L"PATH", ...) or SetDLLDirectory(L"...") into qml.exe would also work, right? Am 25.10.2023 um 12:52 schrieb Ulf Hermann via Development: According to dependency scanner it depends on Qt6Qml.dll, Qt6Core.dll and World.dll. Al

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-25 Thread Elias Steurer via Development
Ahh I get it now, thanks for the help. I do can confirm it does work when putting the dlls into the qt folder. Thanks, Eli Am 25.10.2023 um 12:52 schrieb Ulf Hermann via Development: According to dependency scanner it depends on Qt6Qml.dll, Qt6Core.dll and World.dll. All of these should be ei

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-25 Thread Ulf Hermann via Development
According to dependency scanner it depends on Qt6Qml.dll, Qt6Core.dll and World.dll. All of these should be either be available from Qt or from the additional import path I provided. Even when copying the dlls into the directory, I get the same error. This is not about the import path but abou

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-25 Thread Elias Steurer via Development
According to dependency scanner it depends on Qt6Qml.dll, Qt6Core.dll and World.dll. All of these should be either be available from Qt or from the additional import path I provided. Even when copying the dlls into the directory, I get the same error. PS C:\Qt\6.7.0\msvc2019_64\bin> .\qml.exe

Re: [Development] Using qml.exe with a custom QML_ELEMENT plugin

2023-10-25 Thread Ulf Hermann via Development
PS C:\Qt\6.7.0\msvc2019_64\bin> /.\qml.exe -I "C:\Code\Cpp\build-qml-plugin-minimal-Desktop_Qt_6_7_0_MSVC2019_64bit-Release" -f "C:\Code\Cpp\qml-plugin-minimal\Main.qml" QQmlApplicationEngine failed to load component file:///C:/Code/Cpp/qml-plugin-minimal/Main.qml:5:1: Die Bibliothek C:\Code\Cpp