简体   繁体   English

无法将 python 转换为 exe

[英]Cannot convert python to exe

I have create a simple python program, it's stored in a folder on desktop I opened CMD, set the current directory as the one where the file is located.我创建了一个简单的 python 程序,它存储在桌面上的一个文件夹中 我打开 CMD,将当前目录设置为文件所在的目录。

Then i used pyinstaller MAIN.py (where MAIN is the filename)然后我使用了 pyinstaller MAIN.py (其中 MAIN 是文件名)

在此处输入图像描述

But it's still showing that script is not found.但它仍然显示找不到脚本。 what to do in this case?在这种情况下该怎么办?

could it be that you saved your MAIN.py file with a space after the MAIN?可能是您在 MAIN 之后用空格保存了 MAIN.py 文件吗? It looks at least on the screenshot like this:).它至少在屏幕截图上看起来像这样:)。 So [MAIN(space).py].所以 [MAIN(space).py]。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM