我正在执行此错误:DLL加载失败:找不到指定的模块

时间:2019-02-01 04:59:59

标签: pyqt4 python-3.6

  

回溯(最近通话最近):文件   “ G:\ Automatic-Attendance-System-master \ main_window.py”,第1行,在          从PyQt4导入QtGui,QtCore ImportError:DLL加载失败:找不到指定的模块。

我已经安装了python 3.6.5 64位并安装了SIP和PyQt4 64位库。但是我无法运行此代码。它显示DLL加载失败。

from PyQt4 import QtGui,QtCore
from registration_window import RegistrationWindow
from attendance_window import AttendanceWindow

class MainWindow(QtGui.QMainWindow):
    #Main Window of Interface
    def __init__(self):
        super(MainWindow, self).__init__()
        self._registration_window = None
        self._attendance_window = None
        self.setGeometry(300,50,800,600)
        self.setWindowTitle("Automated Attendance System")
        self.setWindowIcon(QtGui.QIcon('other_images/logo.png'))

    #Heading
    h=QtGui.QLabel(self)
    h.setAlignment(QtCore.Qt.AlignCenter)
    h.setGeometry(QtCore.QRect(100,30,600,60))
    h.setStyleSheet("QLabel { background-color : blue;color :white ; }")
    font=QtGui.QFont("Times",20,QtGui.QFont.Bold)
    h.setFont(font)
    h.setText("AUTOMATED ATTENDANCE SYSTEM")

    #Registration Button for opening registration window
    b1=QtGui.QPushButton(self)
    b1.setText("REGISTRATION")
    font1=QtGui.QFont("Times",16,QtGui.QFont.Bold)
    b1.setFont(font1)
    b1.setGeometry(450,200,200,50)
    b1.setStyleSheet("QPushButton { background-color : gray;color :black ; }")
    b1.clicked.connect(self.create_registration_window)

0 个答案:

没有答案