Convert Tkinter Python App to Executable (.Exe) File [pyinstaller]

Поделиться
HTML-код
  • Опубликовано: 23 ноя 2024

Комментарии • 213

  • @falconimusfalconimus5103
    @falconimusfalconimus5103 9 месяцев назад +71

    TLDR: you need to "pip install pyisntaller" and then execute "pyinstaller (python file) --onefile -w

    • @shameelnkosi
      @shameelnkosi 5 месяцев назад +14

      🤣 you condensed the entire video into one sentence

    • @RoshiAILol
      @RoshiAILol 3 месяца назад

      is "pyisntaller" deliberate?

  • @lamborghinicentenario2497
    @lamborghinicentenario2497 9 месяцев назад +26

    The only person who explains how to remove the console window! Thank you!

  • @tb9359
    @tb9359 Год назад +5

    I agree with ALL the previous affirmative comments. :) Great, concise, easy to understand. No extraneous information!! Just great content.

  • @greenstonegecko
    @greenstonegecko 8 месяцев назад

    very concise while still keeping the most precious details

  • @andreatreto9953
    @andreatreto9953 Год назад +8

    I have exactly those problems and i didn't know how to solve them until i watched your video, great explanation :)

  • @real31iger
    @real31iger 12 дней назад +1

    Hey :) You dont need to delete old files, you can choose the command --clean that will overwrite old files (with the same name) like --name "myFile"

  • @elmehdiouafiq
    @elmehdiouafiq Год назад +7

    Thank you! Very straightforward and great explanation!

  • @sandeeepkiran1130
    @sandeeepkiran1130 6 месяцев назад +2

    Perfect! And the video is segmented too. Even better.
    Super straight forward!

  • @joshuaedward6893
    @joshuaedward6893 11 месяцев назад +2

    thanks for this, it was straight the point I really like how you looked into those other edgecases

  • @Samotric
    @Samotric 2 месяца назад

    I appreciate the detailed explanation and hiding the console part. Thank you.

  • @elfejermohamedtaha4816
    @elfejermohamedtaha4816 8 месяцев назад

    thank you , so much , The only person who explains how to remove the console window!

  • @Native_love
    @Native_love Год назад +1

    You are the greatest teacher EVER!!!!

  • @Mottotech
    @Mottotech Год назад

    Yes she is tech very easily and easy steps no any complicated step and in reality this easy but another youtubers make you confuse

  • @isaacfigueroa
    @isaacfigueroa Год назад +16

    Exactly what I was looking for. Great explanation. Thanks!!!

  • @venkateshsivadurga6456
    @venkateshsivadurga6456 9 месяцев назад

    Thankyou mam for helping me to build my 1st tool using Tkinter. You are amazing. Thanks a lot.

  • @steamersteamer1003
    @steamersteamer1003 Год назад

    You are my first python teacher!

  • @ednueljaytongol8179
    @ednueljaytongol8179 Год назад +1

    You're video exactly what I need into our Capstone project, Thanks a lot, May God Bless you🥰

  • @endeavourtheno.1783
    @endeavourtheno.1783 8 месяцев назад

    Thanks a lot. I have been searching for this video for a long time. Fantastic explanation.

  • @Sam_73378
    @Sam_73378 3 месяца назад +1

    What to do if i have a folder with the code file and other bunch of files which are referenced in code by name only (not by full path)?should i just enter full paths and make the main code file into exe or is there any other method

  • @AshrafulHussainKhan
    @AshrafulHussainKhan 14 дней назад

    I see the application opening time is very much noticable for this simple application. How do you think this would be even useful for bigger applications.
    How to optimise the load time. Do you suggest any other ways to do it.

  • @nubiancenter5918
    @nubiancenter5918 6 месяцев назад

    Thank you sis Hala , straightforward and great explanation!, keep this great work on , may Allah bless you

  • @ReneGalind0
    @ReneGalind0 Год назад +4

    Excellent video!!, But one question, how do you prevent the executable from detecting it as a virus?

    • @studiotutorial
      @studiotutorial Год назад

      its a safeguard by windows to stop unknown executables from being ran. if you have a more official application, you could get a license from microsoft

  • @rexzeltudtud8244
    @rexzeltudtud8244 Месяц назад

    Thank you so much. You're videos are great help to me. 😊

  • @mikebrignol157
    @mikebrignol157 10 месяцев назад

    Very concise and clear, Well done

  • @rajeevchoudhary2420
    @rajeevchoudhary2420 6 месяцев назад

    Very straightforward. Noo time waste 🙏 thx

  • @muhtasimshadab3428
    @muhtasimshadab3428 Год назад

    made my tkinter app to an executable using pyinstaller. Getting error while running the app - "Windows cannot access the specified device , path, or file. You may not have the specified permission to access the item.
    ************** NEED HELP *****************

  • @amusaber6648
    @amusaber6648 4 месяца назад

    Thank You Great explanation. i have a question
    How to build Executable (.exe) file from Python for all Versions of Windows (Seven,8,10,11)
    i used PyInstaller in windows 10 ,but the Executable file compiled by PyInstaller does not work on Windows 7

  • @asenvelkov301
    @asenvelkov301 Год назад

    I had 6 nested tkinter files and everything works, except my main program. None of the functions work, it throws tons of errors in the console, but when i run my project in python its all good, no idea, thanks for the shared info tho

  • @ppol4264
    @ppol4264 5 месяцев назад

    Great video. Very clear.
    However you configure the file explorer to display the file extensions

  • @ongky9047
    @ongky9047 11 месяцев назад

    Very useful video for the beginner of python to convert the .py file to exe file type. But for my situation, i need to use the "python -m PyInstaller main.py --onefile -w"

  • @ddabrahim
    @ddabrahim Год назад +1

    Nice, but if I use other libraries, it does not include it. Any idea how to include libraries with pyinstaller? Thanks.

  • @kumarrao-g2k
    @kumarrao-g2k 3 месяца назад

    Very useful. thanks Hala. I have an issue, the final output has an app and an executable file. The app doesnt work in the sense that it only takes the inputs but does not open up the target folder in my program. it works only with the exe file and not the app file. So the app file is redundant. How do I merge the executable file and the app file.

  • @wad-dx8vi
    @wad-dx8vi Год назад +2

    it is a good video, it explains 3 questions I am facing. Thank you so much!

  • @simsij
    @simsij Год назад

    Perfect, I was looking for this! Subscribed already!!

  • @ndiayepapaamadou
    @ndiayepapaamadou 10 месяцев назад

    explain it to you very well. Thanks for the demo 🤩

  • @omarel-khiali8314
    @omarel-khiali8314 Год назад +1

    Amaaaazing..! I like your explanation, i could understand what i do and why..!!

  • @The_French_Master_Gh
    @The_French_Master_Gh Год назад +1

    Can you please convert customtkinter python app to exe.
    I have tried it but I ended up with an error message

  • @SHD-W
    @SHD-W 5 месяцев назад

    This is what happens
    C:\Windows\System32>pip install pyinstaller
    'pip' is not recognized as an internal or external command,
    operable program or batch file.
    please help

  • @Ashiquem-z2m
    @Ashiquem-z2m 9 месяцев назад

    I successfully converted and executed the code. However, when I added a logo image to my code and attempted to convert it into an executable (exe) file, it didn't work as expected. Instead, it only created an image.png file. Please help me

  • @brijrajkacha9839
    @brijrajkacha9839 Год назад +3

    I downloaded pyinstaller but still it says : 'pyinstaller' is not recognized as an internal or external command,
    operable program or batch file.
    what to do??

    • @richardmagala6442
      @richardmagala6442 Год назад

      restart your terminal and try again

    • @PsuedoPlus
      @PsuedoPlus Год назад

      @@richardmagala6442 it still did not work unfortunately

    • @georgecarlinismytribe
      @georgecarlinismytribe Год назад

      I have the exact same issue: 'pyinstaller' is not recognized as an internal or external command,
      operable program or batch file.
      I've made sure that pyinstaller is installed correctly, so that isn't the problem.
      .

    • @RealCreepaTime
      @RealCreepaTime Год назад +1

      A fix for this is "python -m PyInstaller" Then run whatever she said to do, this should fix your issues, worked for me, just make sure P in Py and i in Installer are both capitalized otherwise it WILL NOT work. Good luck and hope this helps! @Quantum Mechanic @NFxSwoops
      Edit: Man how the hell do these @ things work lol

    • @Jvcques
      @Jvcques Год назад +1

      @@georgecarlinismytribe I fixed this recently, you have to modify your user enviroment variable to include
      "C:\Users\[USERNAME]\AppData\Local\Programs\Python\PythonXXX\Scripts"
      Once you've done this you have to uninstall and reinstall "pyinstaller"
      then in your terminal use Pyinstaller to check if pyinstaller has installed correctly, Hope this helps.

  • @Nonameviewer
    @Nonameviewer 2 года назад +3

    this was really helpful, well-explained! thank you!!

  • @azzedinebekkar2813
    @azzedinebekkar2813 Год назад +4

    Très bien expliqué. Thank you very much

  • @galaxxy09
    @galaxxy09 9 месяцев назад +1

    What font are you using in vscode?

  • @mahmoudhassan6733
    @mahmoudhassan6733 27 дней назад

    Do you need the destination computer to be running python for this to work ?

  • @jucerago
    @jucerago Год назад +1

    It worked well, thank you, well explained. The best tutorial for this topic.

  • @NBWebDev
    @NBWebDev Год назад

    Thanks for this! You absolutely deserve more subs!

  • @Blazikan78
    @Blazikan78 8 месяцев назад +1

    i dont have a single file project.. actually my main file gets some functions from another file and some images from a 'assets' folder.. so will this work the same ?

    • @Guihcouto
      @Guihcouto 4 месяца назад

      I have the same question.

    • @isaakmwangi4618
      @isaakmwangi4618 3 месяца назад +1

      @@Guihcouto You use streamlit or gradio

  • @BraMarsili
    @BraMarsili Год назад

    Thanks for the information! Just a QQ - This would work in the same if I've several libraries others than Tkinter, like pandas, openpyxl, etc... right?

  • @maryamraza8850
    @maryamraza8850 4 месяца назад

    I am getting this error "C:\Windows\System32\Executable File>python -m pyinstaller --onefile -w Data_Entry_Form.py
    C:\Program Files\Python311\python.exe: No module named pyinstaller" how can I fix it?

  • @hasibulalamprionto2010
    @hasibulalamprionto2010 Год назад

    Thank you very much! This tutorial is really helpful!!

  • @sanketss84
    @sanketss84 Год назад +1

    Thanks a ton. exactly what I was looking for and you answered all my questions.

  • @brianmitchell9890
    @brianmitchell9890 10 месяцев назад

    Thank you for the great explanation!!

  • @Javier_Chang
    @Javier_Chang 10 месяцев назад

    it is very clearly for your explanation

  • @mikatamm
    @mikatamm 5 месяцев назад

    Does these PyInstaller exe files trigger antivirus scanners to block them?

  • @chriszethird
    @chriszethird 2 года назад +15

    Really helpful but in the case you have several files codependent from one another, how do you compile everything into one single exe?

  • @C-ti8fx
    @C-ti8fx Год назад +1

    This is interesting, but I don't know where WINDOWS 12??? Please, help me with my quick line.

  • @omudugavu
    @omudugavu 11 месяцев назад

    your a good teacher. JESUS bless you more

  • @harisimranetpa
    @harisimranetpa Год назад +1

    How to make an application (with multiple files and folders) built in other programming languages ​​into an .exe?

    • @harisimranetpa
      @harisimranetpa Год назад

      A video like the one above which clearly explains the above question would be great

  • @kostashow
    @kostashow 10 месяцев назад

    I receive this message "'pip' is not recognized as an internal or external command,
    operable program or batch file." !!
    Any suggestions?? (don't shoot me, i'm not a programmer. i just started to code :D)

  • @bryancaracas7079
    @bryancaracas7079 Год назад

    Hi. Do you have a recommended app for the converted py file to exe file to convert it again, but this time to apk file (to run it on android).
    Thanks

  • @AfroSoul.0
    @AfroSoul.0 9 месяцев назад

    hey hala i hope you're doing good i have a pblm they give me this message 'pyinstaller' is not recognized as an internal or external command,
    operable program or batch file.

  • @tomkmb4120
    @tomkmb4120 Год назад

    Great video. Out of interest, why would someone opt to NOT use the one file flag?

  • @lizandros.4484
    @lizandros.4484 Год назад +1

    how do i create a one fille but i need to add a necesary image ....

  • @user-fn1td6pl9n
    @user-fn1td6pl9n 4 месяца назад

    How can I modify the python version? Does it work with Anaconda python envirenment, too?

  • @subhajitsamanta612
    @subhajitsamanta612 Год назад

    👍 But I have a question. How to do the same conversion if I have assets and database with a .py GUI file? Your response will help me.

  • @swetco
    @swetco Год назад +1

    Excellent presentation. Is there a way to include a logo?

  • @gallezzo6650
    @gallezzo6650 Год назад

    Very clear instruction. Good work

  • @rizz.boy47
    @rizz.boy47 10 месяцев назад

    My program keeps crashing, even when I follow the instructions, is there something else different I should do about this issue?? Thanks

  • @felomwend4377
    @felomwend4377 4 месяца назад

    Thank you mom, it worked very nice to me

  • @SendItive
    @SendItive 5 месяцев назад

    Tkanks but why is treeview window messed up in exe file?

  • @sumitkumargupta1720
    @sumitkumargupta1720 Год назад

    Thank you so much for posting such useful video

  • @yesidcastro408
    @yesidcastro408 8 месяцев назад

    What would it be like to export if you use database and more files. Py?

  • @darklevi7
    @darklevi7 Год назад

    that's what I was searching for, thanks a million go ahead you're spectacular

  • @SdShr-zh8ee
    @SdShr-zh8ee 10 месяцев назад

    There is problem happen .. the interface is not appear .. the black window appear for a second then disappear .. I want the solution please

  • @oslavid
    @oslavid 6 месяцев назад

    Do you know how to include the gspread module?, I got the error: Traceback (most recent call last):
    File "main.py", line 3, in
    ModuleNotFoundError: No module named 'gspread'

    • @oslavid
      @oslavid 6 месяцев назад

      I resolved it!!! 😊

  • @pradachan
    @pradachan 7 месяцев назад +1

    can u combine all pip modules in it?

  • @alexmattyou
    @alexmattyou Год назад

    Clearly explained thanks

  • @proteansan5141
    @proteansan5141 Год назад

    That was really helpful, Thank you!

  • @ExcellentBlog
    @ExcellentBlog 4 месяца назад

    Amazing tutorial. Thank you

  • @_mishki_
    @_mishki_ 10 месяцев назад

    hey it gives me a error mesage saying:
    Traceback (most recent call last):
    File "AZORUS_AUTO_CLICKER.py", line 2, in
    File "bdb.py", line 90, in trace_dispatch
    File "bdb.py", line 114, in dispatch_line
    File "pdb.py", line 340, in user_line
    File "pdb.py", line 438, in interaction
    File "pdb.py", line 401, in _cmdloop
    File "cmd.py", line 126, in cmdloop
    RuntimeError: input(): lost sys.stdin
    tf do i need to do. it says that the problems is with import ctypes as ct

  • @mking1982098
    @mking1982098 6 месяцев назад

    Very nice! This is a great video and resolves most of the issues I was concerned with! Two questions though: Does anyone know (video creator or comment reader) whether this will also work with custom TKinter? Also, if I am building something that requires reading in a file (like a CSV of data for example) is there a way with the "one file" approach to keep the CSV separate so you aren't encapsulating multiple MB of data into the .exe file (also because the data in the CSV will get updated from time to time and it would be nice to not have to recompile every time)?

  • @edappalkkaran
    @edappalkkaran Год назад

    hi, can we put py codes in to diff .py files and make individual exe files for a project ?

  • @e-techwithluckey9211
    @e-techwithluckey9211 2 месяца назад

    Thankyou beauty. Very usefull❤

  • @romariomorrison117
    @romariomorrison117 Год назад

    You are greatly appreciated. Thank you.

  • @wickedsnuk3812
    @wickedsnuk3812 6 месяцев назад

    Do you know how to do this in mac ? tkinter with pyinstaller on mac is something else I guess

  • @nikhil3893
    @nikhil3893 Год назад +1

    will pyautogui works in exe file

  • @vegaswould
    @vegaswould Год назад

    whenever i use Tkinter, i get errors after i convert to an exe. not sure why, but it only works on computers that already have python installed. any other computers use the exe file, errors.... pretty lame. i like tkinter. however, when i use PyQt5, never any problems.

  • @explorerofinfinity722
    @explorerofinfinity722 Год назад

    Excellent video. Many Thanks.

  • @hasibulalamprionto2010
    @hasibulalamprionto2010 Год назад

    In my cmd, when i press enter after writing the command,,, it says that-
    'pyinstaller' is not recognized as an internal or external command, operable program or batch file.
    How can i solve this problem?

    • @bonatate1457
      @bonatate1457 8 месяцев назад

      type this instead:
      python -m PyInstaller --onefile (name of file you'd like to convert)
      example:
      python -m PyInstaller --onefile application_form.py

  • @micheltorres65
    @micheltorres65 Год назад

    Very good explanation, congrats!

  • @hetvishah926
    @hetvishah926 Год назад

    but what about When we have database connection file along with main file itnt working mam

  • @NK-vw2rl
    @NK-vw2rl 5 месяцев назад

    Great tutorial, thanks a lot :)

  • @faaiidodiineed6924
    @faaiidodiineed6924 Год назад

    Thank you for effort and helpful videos.

  • @alielsheikh8091
    @alielsheikh8091 Год назад +1

    Hello, very useful indeed thank you. However what if I have a background image and program icon included in my script
    When I convert to Exe and run on another computer it gives error of missing background and Icom in path xxxxxxx.
    How can I resolve this issue?
    Thanks in advance

    • @gauravkushwaha4497
      @gauravkushwaha4497 Год назад

      i am also facing the same problem

    • @richardmagala6442
      @richardmagala6442 Год назад

      I just put them in the same script as the application. it works very fine

    • @alielsheikh8091
      @alielsheikh8091 Год назад

      @@richardmagala6442 I will try this out and let you know.
      Thanks for sharing and support.

    • @alielsheikh8091
      @alielsheikh8091 Год назад

      @@richardmagala6442 Hello Richard, i added the logo & the icon to the script folder and converted to exe but still getting this error of the missing files even on my laptop: _tkinter.TclError: couldn't open "pass background2.png": no such file or directory

    • @nocco0759
      @nocco0759 Год назад

      @@alielsheikh8091 Hello, this is bit late but i hope you got the answer if you didn't, you need to put your logo and icon in the same folder as your exe, i had the same problem but once i put my logo and icon in the same folder as my exe it worked, hope this would fix your problem

  • @abdielpuello7209
    @abdielpuello7209 5 месяцев назад

    I need to do this but with a Mac laptop which so far has been a big problem for me. Does someone knows how?

  • @ZaeNonQ
    @ZaeNonQ 2 года назад

    Yeah,it did compiled,but i cant run it (im using python 3.10.6 + customtkinter libary)

  • @deepbhuptani2778
    @deepbhuptani2778 Год назад

    Really helpful learning python.
    Just one quick question,
    Does python need to be installed to run this exe, or we can run this exe in any system without python installed in it?

  • @HarshaVardhanBandaru-r6h
    @HarshaVardhanBandaru-r6h 10 месяцев назад

    I tried this and Windows Defender Immediately said it detected a Trojan Horse (Win64/Malgent!MSR), and it only affected my .py (exe) file that was created... is this normal? I immediately removed it but I don't know what happened.

    • @oshakiegittens4887
      @oshakiegittens4887 5 месяцев назад

      I have the same program, did you figure it out?

  • @nchnnnn
    @nchnnnn 11 месяцев назад

    Why my exe file detect by windows defender? how to convert exe not detecting by windows 10?

  • @zigaudrey
    @zigaudrey Год назад

    How to deal with false positive after creating an exe file?