An error appears when you create an exe file with code saved as Python Excel.

Asked 2 years ago, Updated 2 years ago, 106 views

Hello.

I made a file that saves the output value in Excel using openpyxl.

Put the from openpyxlimport workbook in the first line of coding

I've also finished installing the openpyxl package.

But the problem is that if you run this code in Faicham, you'll be able to run it on a normal path

Files are saved properly

pyinstaller-F If you create an execution file with this and run it, an error occurs.

What's the reason? I'm a beginner, so I'm asking you a question because I couldn't solve it.

Please solve this problem

Error phrases are

Traceback (most recen call last):

file "file name.py", line 1, in

ModuleNotFondError : No module named 'openpyxl'

[32096] Failed to execute script file name

It pops up like this.

It seems that there is no openpyxl module

I installed openpyxl in Faicham, do I need to install more?

I'm also wondering if it's not possible to use it on PCs without openpyxl.

openpyxl

2022-09-21 15:35

1 Answers

Try again.

pyinstaller-F --hidden-import=openpyxl filename.py


2022-09-21 15:35

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.