At last I finished a my code in Python and converted it to .exe file using py2exe. Program works correctly at my personel computer but when I try it at my office, I got a fatal error: "Could not load python library". Both computers have the same version of Python and I am sure that I carried all files. Just my pc is Windows 10 and the other one is Windows 7. Could you please help me?
Asked
Active
Viewed 1,228 times
0
-
Maybe adding libraries manually will be helpful https://stackoverflow.com/a/43940863 – Dudnikof Jun 03 '21 at 08:23
-
This makes sense, Dudnikof thank you! But I'm not sure how to include some of the libraries. Lines on this topic in my current setup file is as follows: includes = ["tkinter", "sys", "ttk", "Pandas", "docx", "Document", "Pt", "WD_ALIGN_PARAGRAPH", "lxml._elementpath"] setup(console=['Combobox.py'], data_files = Mydata_files, options={"py2exe": {"compressed": 0, "includes": includes, "unbuffered": True, "optimize": 2, "bundle_files": 1, }}) – mdiramali Jun 03 '21 at 11:12
-
1Is it possible that one of the computers is 64-bit and the other not? `py2exe` can't do cross-compilation. Also, the section in the documentation called *When things go wrong* has specific advice about targeting Windows 7. – BoarGules Jun 03 '21 at 12:07
-
Thank you, Boargules but both computers are 64-bit. I'll look to the When things go wrong section. – mdiramali Jun 03 '21 at 14:30