A
A
Artyom2018-04-24 18:44:14
Python
Artyom, 2018-04-24 18:44:14

Compiling a python 3.6 file with tkinter via cx_Freeze: what's wrong?

I'm trying to compile a python file (.pyw in my case) using cx_Freeze. The program actively uses:

  • Format strings, only added in python v3.6 (looks like f"texttext{<variable from code>}text"
  • MySQL library
  • tkinter

This is how the setup.py file for compiling cx_freeze looks like:
import sys
from cx_Freeze import setup, Executable
build_exe_options = {"packages": ["os"], "excludes": ["tkinter"]}
base = None
if sys.platform == "win32":
    base = "Win32GUI"

setup(name = "my prog",
    version = "1.0",
    description = "My application!",
    options = {"build_exe": build_exe_options},
    executables = [Executable("main.pyw", base = base)])

python setup.py build
I execute When I run the finished exe I get: "The program cannot be started because VCRUNTIME140.dll is missing on the computer. Try reinstalling the program. "
Where is the mistake? The program itself works fine.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question