marticliment / win32mica

Win32mica: a simple module to add the Mica effect on legacy python windows.
https://pypi.org/project/win32mica
MIT License
95 stars 5 forks source link

Compiling with cx_Freeze #6

Closed not-nef closed 2 years ago

not-nef commented 2 years ago

Hello! I am using win32mica in a program, and when running the program from the .py file, everything works flawlessly. But when i compile the program to an execuetable using cx_Freeze, win32mica throws the following error:

Win32Mica Error: win32 version 9200 is not supported

What does that mean and how do i fix it?

marticliment commented 2 years ago

Mhmm, that's weird... It looks that cx_freeze is not providing a correct windows build number...

Could you try build using PyInstaller?

not-nef commented 2 years ago

I can, but does pyinstaller build msi's?

marticliment commented 2 years ago

PyInstaller will build a standalone .exe file, and then you can create an installer using tools like Inno Setup (will create a .exe installer) or AppDeploy Repackager (will create a .msi installer)

not-nef commented 2 years ago

Epic, ok. How do i use pyinstaller? (Sorry for bothering you)

marticliment commented 2 years ago

It is really easy (actually easier than cx_freeze).

  1. install pyinstaller:

    pip install pyinstaller
  2. Build the .exe file:

    pyinstaller ./yourfile.py --onefile --windowed
  3. You will have a .exe file in a folder located in your current working directory called dist. It should work then.

For more info check out the docs: https://pyinstaller.org/en/stable/usage.html

marticliment commented 2 years ago

Hi, did that help with the issue?

not-nef commented 2 years ago

I am still having troubles with another of the apps components, but once its fixed, i will report to you if it works!

not-nef commented 2 years ago

Yes @martinet101 it works, thank you