当我在命令提示符下尝试 pyuic4 -o hello.py hello.ui
时,出现错误
python26.dll was not found
我下载了相同的文件并复制到C:\windows\system32\...
。但是现在我收到以下错误:
C:\>pyuic4 -o hello.py hello.ui
Traceback (most recent call last):
File "C:\Python26\Lib\site-packages\PyQt4\uic\pyuic.py", line 4, in <module>
from PyQt4 import QtCore
ImportError: Module use of python26.dll conflicts with this version of Python.
解决方案是什么?
最佳答案
i installed PyQt-Py2.6-gpl-4.7-1.exe and python-2.5.msi
二进制包是针对特定的 python 版本编译的。
您应该始终安装与您安装的 python 版本相对应的二进制包。 python 版本通常在包的名称中指示。在您的例子中,Py2.6
表示此 PyQt 发行版将与 Python 2.6 一起安装。
关于找不到 python26.dll,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8531003/