Python Forum

Full Version: [Solved] Help with an DLL import error
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

I have a quick script that should let me view the GUI.
But when I run it I get this error:
Error:
from PyQt6.QtWidgets import QApplication ImportError: DLL load failed while importing QtGui: The specified procedure could not be found.
Does anyone know how I can fix this?

Thanks in advance.


The code:
from PyQt6 import uic
from PyQt6.QtWidgets import QApplication

Form, Window = uic.loadUiType("LoginScreenGUI.ui")

app = QApplication([])
window = Window()
form = Form()
form.setupUi(window)
window.show()
app.exec()
Fixed it. Just changed PyQt6 to PyQt5
This is how I show PDF in PyQt5, external modules are not required.
You need to reinstall PyQt6 with this command in Windows OS:

pip3 install PyQt6 --user --ignore-installed
Make a search with my nickname catafest and you will find my blog about python
Everything works properly when changed PyQt6 to PyQt5
Drift Boss