Created
          September 6, 2020 19:09 
        
      - 
      
 - 
        
Save EbrahimGhanbari/529ed870508395b4df25be426c73e31c to your computer and use it in GitHub Desktop.  
    udemy_python_tkinter_kmToMile_App
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | from tkinter import * | |
| window=Tk() | |
| def kmToMiles(): | |
| miles = float(e1_value.get())*(1/1.6) | |
| t1.insert(END, miles) | |
| b1=Button(window, text="Execute", command=kmToMiles) | |
| b1.grid(row=0, column=0) | |
| e1_value=StringVar() | |
| e1=Entry(window, textvariable=e1_value) | |
| e1.grid(row=0, column=1) | |
| t1=Text(window, height=1, width=20) | |
| t1.grid(row=0, column=2) | |
| window.mainloop() | |
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment