Jan-22-2020, 05:04 PM
Okay so I've put the code together, I thought maybe it'd be the submit button which is causing the error but apparently its the indent however it doesn't like being alone?
Error: File "C:/Users/jumbu/Desktop/python", line 20
c.execute("INSERT INTO Expense_Data.db VALUES (?, ?, ?, ?)", (l1.get(), l2.get(), l3.get(), l4.get()))
^
IndentationError: unexpected indent
def submit(): c.execute("INSERT INTO Expense_Data.db VALUES (?, ?, ?, ?)", (l1.get(), l2.get(), l3.get(), l4.get())) payload = (name_text.get(), Monthly_Income_text.get(), Monthly_Budget.get(), Monthly_Expenses.get()) c.execute("INSERT INTO Expense_Data.db VALUES (?, ?, ?, ?)", payload)Maybe I leave payload indented but c.execute elsewhere?