How to find the layout (via blocks) inside which a certain label exists

Greetings,

I have a label, and I need to find the name of the layout inside which it exists.

Here is an example of my component tree.

  • Main [Ver Arr]
    • Row_Time [Hor Arr]
      - Time_1 [Hor Arr]
      - T1_Label [Label]
      - Time_2 [Hor Arr]
      - T2_Label [Label]
      - Time_3 [Hor Arr]
      - T3_Label [Label]
    • Row_Sat [Hor Arr]
      - Sat_1 [Hor Arr]
      - Sat1_Label [Label]
      - Sat_2 [Hor Arr]
      - Sat2_Label [Label]
      - Sat_3 [Hor Arr]
      - Sat3_Label [Label]
    • Row_Sun [Hor Arr]
      - Sun_1 [Hor Arr]
      - Sun1_Label [Label]
      - Sun_2 [Hor Arr]
      - Sun2_Label [Label]
      - Sun_3 [Hor Arr]
      - Sun3_Label [Label]

If I am working with the label T1_Label, how do I find the parent layout of this label, that is Time_1?

I guess there may be an extension that will allow me to do that. I will be grateful if anyone can point me in the right direction.

Do you have this data in a list, or just in a label ?

If in a label this will be a string (text) so you can use the split by block and split at Time_1.

But actually I believe you want to return the values in T1_Label, T2_Label and T3_ Label ?

What I really want to do is change the background colour of the horizontal arrangement inside which the label exists. I do know how to change the bg colour via blocks, but I need the horizontal arrangement so that I can change its bg colour. BTW I only have the labels inside a list, not the arrangements.

The secret here is to arrange components in lists & tables, and refer to them by row and column numbers.
Here is a sample project using buttons, that derives the row and column number of a button from its Click event ...