我在用导入PytQ5的uic时报错,代码如下
import sys
from PyQt5 import QtWidgets,uic
from_class = uic.loadUiType("untitled.ui")[0]
class MyFirstWindow(QtWidgets.QMainWindow,from_class):
def __init__(self,parent=None):
QtWidgets.QMainWindow.__init__(self,parent)
self.setupUi(self)
app = QtWidgets.QApplication(sys.argv)
mywindow = MyFirstWindow()
mywindow.show()
app.exec_()
报错内容如下:
请各位帮忙解答一下,谢谢!