Home > other >  Python tkinter open the file, appear the CMD window (in the case of not opened the program)
Python tkinter open the file, appear the CMD window (in the case of not opened the program)

Time:10-22

In tkinter created a button, click it will open the specific file, use the OS. The system (file_path) method, in pycharm runtime to open the file, but use pyinstaller packaged into exe, open the file at the same time will open the CMD window (have the suffix to pyw), when not open exe CMD, but after open the program, click on the button, open a file at the same time there will be a CMD (system32 \ CMD exe), and after I closed the program, CMD window, feeling is to open a text file method can open it at the same time, beg god to help small white is to see why, can't get this CMD window does not appear,

CodePudding user response:

Checked the because the OS. The system calls the CMD, so there will be

CodePudding user response:

Resolved, substitute the subprocess for OS. The system

CodePudding user response:

Resolved, substitute the subprocess for OS. The system
  • Related