1. <tfoot id='kLHY4'></tfoot>

        <small id='kLHY4'></small><noframes id='kLHY4'>

        <i id='kLHY4'><tr id='kLHY4'><dt id='kLHY4'><q id='kLHY4'><span id='kLHY4'><b id='kLHY4'><form id='kLHY4'><ins id='kLHY4'></ins><ul id='kLHY4'></ul><sub id='kLHY4'></sub></form><legend id='kLHY4'></legend><bdo id='kLHY4'><pre id='kLHY4'><center id='kLHY4'></center></pre></bdo></b><th id='kLHY4'></th></span></q></dt></tr></i><div id='kLHY4'><tfoot id='kLHY4'></tfoot><dl id='kLHY4'><fieldset id='kLHY4'></fieldset></dl></div>

          <bdo id='kLHY4'></bdo><ul id='kLHY4'></ul>
        <legend id='kLHY4'><style id='kLHY4'><dir id='kLHY4'><q id='kLHY4'></q></dir></style></legend>

        Python 3.5 + PyQt5 到独立 exe

        时间:2023-08-04
      2. <tfoot id='yEwxI'></tfoot>
      3. <small id='yEwxI'></small><noframes id='yEwxI'>

          <i id='yEwxI'><tr id='yEwxI'><dt id='yEwxI'><q id='yEwxI'><span id='yEwxI'><b id='yEwxI'><form id='yEwxI'><ins id='yEwxI'></ins><ul id='yEwxI'></ul><sub id='yEwxI'></sub></form><legend id='yEwxI'></legend><bdo id='yEwxI'><pre id='yEwxI'><center id='yEwxI'></center></pre></bdo></b><th id='yEwxI'></th></span></q></dt></tr></i><div id='yEwxI'><tfoot id='yEwxI'></tfoot><dl id='yEwxI'><fieldset id='yEwxI'></fieldset></dl></div>

          1. <legend id='yEwxI'><style id='yEwxI'><dir id='yEwxI'><q id='yEwxI'></q></dir></style></legend>
            • <bdo id='yEwxI'></bdo><ul id='yEwxI'></ul>
                <tbody id='yEwxI'></tbody>
                  本文介绍了Python 3.5 + PyQt5 到独立 exe的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我是编码新手,我需要将我的 py 文件转换为 exe.我尝试了 py2exe,但它不适用于 python 3.5.然后我尝试了pyinstaller并且它工作了,但是当我将PyQt5添加到程序中时,pyinstaller也失败了.我尝试了nuitka,它构建了exe,但是当我单击exe文件时,它会显示一个控制台几秒钟并关闭.我需要一个在激活后显示 gui 的 exe.以下是我在程序中使用的模块:

                  I'm new to coding and I need to transform my py file to an exe. I tried py2exe and it didn't work with python 3.5. Then I tried pyinstaller and it worked, but when I added PyQt5 to the program, pyinstaller also failed. I tried nuitka, and it builds the exe, but when I click on the exe file it shows a console for a few seconds and closes. I need an exe which shows a gui after being activated. Here are the modules that I used in the program:

                  import P4
                  import time
                  from datetime import datetime,date
                  import traceback
                  import os
                  import sys
                  import threading
                  from PyQt5 import QtCore
                  from PyQt5 import QtGui
                  from PyQt5.QtWidgets import *
                  from PyQt5.QtCore import QCoreApplication, QTimer
                  

                  我从 nuitka exe 文件中得到的错误:

                  Error I get from nuitka exe file:

                  我从 pyinstaller exe 文件中得到的错误:

                  Error I get from pyinstaller exe file:

                  pyinstaller 需要的 Dll:dll

                  Dll's that pyinstaller needs: dlls

                  推荐答案

                  我已经弄清楚如何使用 Python 3.5 和 pyinstaller 制作一个 exe.你需要安装这个:

                  I've figured out how to make an exe with Python 3.5 and pyinstaller. You need to install this:

                  pip install https://github.com/pyinstaller/pyinstaller/archive/develop.zip --upgrade
                  

                  然后添加 PyQt5 dll 的路径.我用这个:

                  Then add path to PyQt5 dll's. I used this:

                  pyinstaller -y --clean --paths C:TEMPenvLibsite-packagesPyQt5Qtin
                  

                  这篇关于Python 3.5 + PyQt5 到独立 exe的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:如何使用 Pyqt5 QtMultimedia 播放声音? 下一篇:线程实时记录

                  相关文章

                  最新文章

                  1. <i id='hikdV'><tr id='hikdV'><dt id='hikdV'><q id='hikdV'><span id='hikdV'><b id='hikdV'><form id='hikdV'><ins id='hikdV'></ins><ul id='hikdV'></ul><sub id='hikdV'></sub></form><legend id='hikdV'></legend><bdo id='hikdV'><pre id='hikdV'><center id='hikdV'></center></pre></bdo></b><th id='hikdV'></th></span></q></dt></tr></i><div id='hikdV'><tfoot id='hikdV'></tfoot><dl id='hikdV'><fieldset id='hikdV'></fieldset></dl></div>
                      <bdo id='hikdV'></bdo><ul id='hikdV'></ul>

                      <legend id='hikdV'><style id='hikdV'><dir id='hikdV'><q id='hikdV'></q></dir></style></legend>
                    1. <tfoot id='hikdV'></tfoot>
                    2. <small id='hikdV'></small><noframes id='hikdV'>