Mar-31-2023, 10:28 PM
(This post was last modified: Mar-31-2023, 10:31 PM by deanhystad.)
Use the Python button in the editor to wrap your code in Python tags.
You still have an error in root().
And you have a new indentation error:
And this indentation is also wrong, though it probably doesn't stop your code running.
You still have an error in root().
And you have a new indentation error:
self.res_label.config(text=result) # create the main window and profit object # create the main window and profit object root = tk.Tk() pro = Profit(root) root.mainloop()As currently written, you are making root inside the calculate() method.
And this indentation is also wrong, though it probably doesn't stop your code running.
def rule(master): return 72/masterThe rest of your code uses 4 space indents. This has 8 spaces. Be consistent.