tksheet icon indicating copy to clipboard operation
tksheet copied to clipboard

span.checkbox

Open Akselrud opened this issue 10 months ago • 1 comments

I created a span.checkbox (Grid1 is Sheet):

           span = Grid1[i1, i2]
           span.checkbox(checked=False, text = "2025")

How do I get the values of i1, i2 when clicking on the checkbox with the mouse, which gives checked=True?

Akselrud avatar Dec 31 '24 13:12 Akselrud

Hello,

As a quick example and going by your example, you could do the following:

values = span.data

But I have also updated the docs for more info on the topic which you can find below, specifically under the Notes section:

https://github.com/ragardner/tksheet/wiki/Version-7#using-a-span-to-create-check-boxes

Notes:

  • To get the current checkbox value either: - Get the cell data, more information here. - Use the parameter check_function with a function of your own creation to be called when the checkbox is set by the user.

ragardner avatar Jan 06 '25 09:01 ragardner