@vladsivolobov

Что это за ошибка и как её исправить?

Сама ошибка:
qt.qpa.plugin: Could not find the Qt platform plugin "windows" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Вот код:

from myprogramm import *
from PyQt5 import QtCore, QtGui, QtWidgets
import sys

class MyWin(QtWidgets.QMainWindow):
	def __init__(self, parent=None):
		QtWidgets.QWidget.__init__(self, parent)
		self.ui = Ui_MainWindow()
		self.ui.setupUi(self)




if __name__=='__main__':
	app = QtWidgets.QApplication(sys.argv)
	myapp = MyWin()
	myapp.show()
	sys.exit(app.exec_())
  • Вопрос задан
  • 384 просмотра
Решения вопроса 1
@antonksa
Open cmd and type echo %QT_PLUGIN_PATH% if it's not empty then delete it (just google: delete environmental variable windows #, where # is your windows version)

Open cmd and type echo %PATH% and press enter. You'll see a list separated by ; of folder paths. Go line by line and make sure they do not point to a folder that contains a platforms folder that has qwindows.dll in it. If you find such a path edit the PATH variable and remove it (just google: edit environmental variable windows #, where # is your windows version)
Ответ написан
Комментировать
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Похожие вопросы