Closed spettitt9095 closed 2 months ago
I think I might have figured this out - I think I need to remove the checkboxes before I try and delete the rows. Testing at the moment.
I think this is my bad - I was looping over rows and columns to add checkboxes, rather than providing a span range. Seems to be working now.
Thanks for your report, sorry for the late reply,
If you have anymore issues let me know
I am not 100% sure but such an error may have been an issue in an older version where in order to undo a change some sheet information is pickled and the pickled information wrongly contained references to tkinter objects which cannot be pickled.
Hello, apologies I'm quite new to Python so this may be user error.
I have an application where I need to add or remove rows from a sheet (rows of checkboxes in banks of 6, but that's probably not relevant here).
I can add them easily:
self.sheet.insert_rows(rows = 6)
. But if I need to delete them, I get TypeError: cannot pickle '_tkinter.tkapp' object. I'm using CustomTkinter but can reproduce the same with normal Tkinter.I've tried del_row and del_rows but both produce the error.
I made a simple reproducible example based one of the tksheet examples. Is there a way to make this work please?
Thank you.
`from tksheet import (Sheet, num2alpha as n2a,) import tkinter as tk
class demo(tk.Tk): def init(self): tk.Tk.init(self)
app = demo() app.mainloop()`