Get the value of <anvil.Component object>

Hi, I am very new to Anvil but so far enjoying it.

I am busy building a price list management tool which is basically a DataGrid with a repeating panel showing products, description and price.
Attached to the repeating panel is a checkbox for the admin to choose which items they want the price adjustment to be applied to.
image

Obviously doing a data bind to a field like “checked” in the data table would be easy but I don’t want the client to write to the data table, so here comes the thing I cant figure out.
I can’t see how to retrieve anything from the line the checkbox is part of.
Knowing the box is checked is easy, but pulling something like the table row ID of the line, or a unique identifier such as product code is stumping me.

No matter what I try I get generic info such as:
self.item = <LiveObject: anvil.tables.Row>
<anvil.Component object>

Please guide me regarding how to, on a check box change, retrieve the data populating the repeating panel line the checkbox is part of.
Once I can retrieve that data from the line I can then write the adjustment back to the data table via a server call, but until I can read the line into a variable all I’m doing is staring at my screen wishing I wasn’t so dumb.

Thanks for the help guys.

1 Like

You are not alone, I encountered the same issue when starting a few weeks ago.
Please see these posts:

Thanks for the reply Tony,
So the issue I am facing is not that I am battling to access the data table, what I can’t figure out is how to access/read/store/retrieve the info on the repeating_panel line that the checkbox is part of.

So, for example if the repeating_panel looked like this with a checkbox at the end of the line:

Product Product Code Price
Abc abc-prod-1 5.00

and the user checked the box to apply the price increase to that line, how would I retrieve “abc-prod-1” to include that in the data table rows that would have the price increase?
Thanks.

Hi @turnip12144, is this your issue?

Do you try the tutorial?