0

is there the possibility to import Tkinter modul in IDE AWS Cloud9 (Python)? This simple program doesn't work (No module name 'Tkinter'). Any suggestion? Thanks

from tkinter import Label # get a widget 
object
widget = Label(None, text='Hello GUI 
world!') # make one
widget.pack() # arrange it
widget.mainloop() # start event loop
John Rotenstein
  • 241,921
  • 22
  • 380
  • 470
Gianluca
  • 19
  • 3

1 Answers1

1

Have you checked tkinter is sucessfully installed or not? check it by using pip freeze

if it is not installed then try this command python3

sudo apt-get install python3-tk

python2

sudo apt-get install python-tk

Mayur Satav
  • 985
  • 2
  • 12
  • 32