Please find below the python code I have written:
from tkinter import *
import os
fenetre = Tk()
label = Label(fenetre, text="Power BI is gonna be open as soon as the program finds an optimal solution.")
label.pack()
fenetre.mainloop()
os.system('cmd /c "pbixrefresher C:\\Users\\LFM\\Desktop\\Optimization.pbix '
'--refresh-timeout 300000 --no-publish --init-wait 6"')
I have used "-w" when I created the exe file with pyinstaller. When I double-clicked on the created exe file, as requested, only a window appears and not the console. Though, Power BI does not open. Power BI opens only when I close the window. And, at that moment, the command prompt appears.
pyinstaller -F ^
-w ^
C:\Users\LFM\PycharmProjects\Tests\Tests.pyw
Is there a way to not open the command prompt even if I use os.system ?