I was trying to code a rectangle in Python Tkinter with the Canvas module, and root is not recognized in the line of code below:
rect = tkinter.Canvas(root, width=550, height=820)
I was reading off another Stack Overflow question linked here, but the code shown there doesn’t seem to be working.
Tkinter Canvas creating rectangle
New contributor
catsandnature is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.