I'm creating UI of a form using Tkinter in Python2 where IDE is PyCharm.
Following is the code for the reference:-
from Tkinter import *;
root = Tk()
root.geometry("400x100")
#adding the header label of the tool.
myheaderTitle = Label(root,text="myForm",bg="lime green",font="Calibri 16 bold",width="400")
myheaderTitle.pack()
button_1 = Button(root,text="Select File")
button_1.grid(row=0,column=0)
root.mainloop()
I'm successful in running the above code, but the form is not visible whenever I add below two lines of code.
button_1 = Button(root,text="Select File")
button_1.grid(row=0,column=0)
What could be the problem with these lines?