Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ##+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++##
- ##=======================================================================================================================================================================================##
- ##----------------------CODEDSKILLS.NET--------------------------------------------------------------------------------------------------------------------------------------------------##
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- from tkinter import * #
- from threading import Thread #
- from tkinter import messagebox #
- from pytube import YouTube #
- #--------------------------------#
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #----------------------------------#------------------------------------------------+-----------------------------+
- def threading(): #
- # Call work function #
- t1=Thread(target=download) #
- t1.start() #---------------+-------------------+----------------------------------+------------------------------------------------+
- #----------------------------------#
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #-------------------------------------#----------------------+--------------------------------+
- def download(): #---------------------#
- url = YouTube(str(url_box.get())) #---------------#
- video = url.streams.first() #---------------------#
- video.download() #-------------------------------#
- messagebox.showinfo('', 'Download completed!') #
- #-----------------------------------------------------#
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #---------------------------------#--------------------------------------------+--------------------------------------------------+
- root =Tk() #----------------------#
- root.title('YouTube Downloader') #
- root.geometry('738x237+500+200') #-------+----------------------------------------------+-------------------------------------------------------+-------------------------------+01010000001+----------------------+
- #root.iconbitmap('youtube.ico') #
- root.configure(bg='black') #---#
- root.resizable(False,False) #
- #-----------------------------#----------+1010000001+----------------------------------------------------+--------------------------------------------+---------------------------------------------+
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #--LABEL WIDGETS----------------------#-------------+---------------------------+-------------------+
- introlable = Label( #-----------------#
- root, #---------------------------#----+----------------101000001-------+---------------+
- text='YouTube Video Downloader', #
- width=30, #------#----------------#-----------------------+-------------------------------------------+-------------------------+
- relief='sunken', #
- bd=4, #----#
- bg="black", #--------------#
- font=('Courier New',26), #
- fg='red') #----------------#
- introlable.place(x=50,y=5) #
- #------------------------------#
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #----------------------------------#------------------+------------------------------------+--------------------------+
- Label( #---------------------------#
- root, #-----------------------#
- text='Enter YouTube Link', #
- font=('Courier New', 12), #
- relief="sunken", #-----------#----------+---------------------+-----------------------------+1010000010+-----------------------+
- bg='black', #------#
- fg="lime", #----------#
- ).place(x=280, y=70) #
- #--------------------------#
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #--ENTRY WIDGETS-#-----------------------+-------------------------------------------------------------------------------------------------------------------+-----------------------+
- url_box = Entry( #
- root, #------#---------------#--------------------------------------------+------------------+-------------+
- font=('Courier New',30),#----#
- width=30 #-------------------#---------+------------------+-----+
- ) #-------------------------#
- url_box.place(x=7, y=110) #--------------+-------------------------------------------+
- #--------------------------------#
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #--BUTTON WIDGETS-------------------#------------------+-----------------------------------------------+----------------------+
- btn = Button( #---------------------#
- root, #------------------------#---------------------+--------------------------------------------------------------------------------------------------+
- text='--DOWNLOAD--', #----------#
- bg="black", #-------------------#
- font=('Courier New', 25), #
- fg="orange", #---#-------------#------+------------------------+010001111001+--------------------------------------+
- command=threading #
- ) #---------------#-------#
- btn.place(x=240, y=165) #
- #-----------------------------#
- #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- #+++++++++++++++#------------------------------+-------------------------------------+
- root.mainloop() #
- #+++++++++++++++#
- ##+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++##
- ##=================================================================================================================================================##
- ##-------------------------------------------------------------------------------------------------------------------------------------------------##
- ## ##
- ## ## // ##
- ##----+-#########\ ######## -+#######\\-- +########## #######\\ /#######\\ ## // ######---+-## ## /#######\\ ##
- ## ##- ##|--|## ##- ## ## ##- ## ||----- ## // ## ##----+-## ||----- +--##
- ## ## ##| |## -+## +--## ####### ## ## -- \\#######\\ ## \\ ## ## ##------\\#######\\-------+##
- ## ##- +-##|--|## ##- ## ## ##- ## ------|| ## \\ ## ## ## ------||--------##
- ## #########/ ######## -#######//- -+########## #######// \\######// ## \\ ######---+-##### ##### \\######//------+--##
- ## ##
- ## https://CodedSkills.net ##
- ##-------------------------------------------------------------------------------------------------------------------------------------------------##
- ##=================================================================================================================================================##
- ##+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++##
- ##+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++##
- ##=======================================================================================================================================================================================##
- ##---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------##
- ## ##
- ## ### #######\ #######\ ####### ######## ## ## ######## ######## ####### ######## #### ## /#######\\ ##
- ## #-## // // \ // = ## ## ## ## ##|--|## ## // ## // \\ ## ||- ##
- ## ## ##\\ ##\\ // ## ## ## ## ##| |## ###\\ ## //====\\ ## \\#######\\ ##
- ## ## // // // ## ## ## ## ##|--|## ## \\ ## // \\ ## || ##
- ## ########## ########-- ########-- // = ## #### ## ######## ## \\ ######## // \\ ####### \\######// ##
- ## ##
- ## https://1337tutorials.net ##
- ##---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------##
- ##=======================================================================================================================================================================================##
- ##+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++##
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement