MIT App Inventor and 100+ esp32, how could I do this?!

what procedure are behind "highlighted" propriety?

as mentioned previously, this is a custom property, you can give any name you want.

A day and a night searching for the best solution to highlight the border of a cell in red, when I touch it the first time, and to revert that border to gray when I touch that same cell the second time.

I have two cases, case A and case B. Case A = is what I find as a solution, it is the plan... B/backup plan, which means if I do not have another solution, this is the solution that I will use in my app, I don't think that is the best, but it is working as expected.

Case A - 3 approaches/tests

Test - 1

Above is test 1 which works as expected/perfectly - first click - border = red, second click - border = gray.

The only logic that I saw is with lists to filter/identify the red/gray cells

Test - 2

Above is test 2 which works as expected/perfectly - first click - border = red, second click - border = gray.

Test - 3


Above is test 3 which doesn't work as exspected! first click - border=red, second click - border=red, it don't revert the border to gray!!!

Why that doesn't work, I don't know. The only difference is that SetAsCard is included in a "custom" procedure.

Case B - one test.

Above I try to recreate the example that Kevin gives me. As expected it doesn't work, it crashes the companion. I think because the "propriety" used as "highlighted" is not defined. Anyway, I don't understand the logic behind it.

Shortest, I can't explain all the above. Anyone can give it a run. Any suggestions/critiques are more than welcome.

KK_1.aia (73.7 KB)

if you already have a solution, no need to use others solution, especially when you don't understand other's logic. there is no standard answer to solve problems.

and here is the issue:


that's why your label can become red, but not gray.

@Kevinkun .Thank you very much Kevin your suggestions always try to follow. I have an existential problem.

I must understand the lists, and how it works. I tried 3 approaches to display the real numbers of cells that are inside the lists as debugging possibilities.. Above is the result. Advise me please how can I see the real numbers from a list and so on.

Thank you very much for your time.

what's this means? this list is containing numbers? but from your code, it's contains components, not number.

The above/blue-marked list I suppose works with numbers, I suppose. Or not work with numbers?! If so that may be my problem. I try to display them with yellow marks. My aia is made as you recommend me. I don't know what I have there... But your idea is genial, I will look at this aspect, thank you.

from your blocks image, it is not from my recommendations.

I'll speak about that part, another part I don't understand yet, I working on it. With what I made, I have a comparison. Now I am working on your last recommendation to understand it and make it work.

This is your last recommendation. I have it as the bible on my left screen together with Tim's example.

I'm very sorry about my "typo" with the color, it was the hurry... It cost me a day and a night.

As usual, it works like a charm.

Next... I need that when I touch a cell, change color to red (that already it does), and deactivate somehow the clicks possibilities on other cells. At the same time, "open" a new "window" / another alignment. That think with the new alignment, I think that I can do it, but how to deactivate the rest of the cells when a cell has red borders?!

Another huge thank you for your time.

As usual, simple as that. These two extensions... Are priceless.

At the same time, I plan to activate another VerticalArrangement where I will enter the data that will customize the used cells. Can be a good approach. And when the customized data are saved, I will reactivate the VerticalArangement1.

I'm on the right path?!

@Kevinkun . Can you please, give me an example or a link about how can I read a button, as a best practice?! I think that I discovered how to generate them.

why a new button needed When highlight a label?

The logic was: when I touch a cell - > border =red and set the visible to false for VerticalArangement2 that hosts all cells (to can't touch another cell from error), generate a button on VericalAlignment1. With that button, I want to make it again visible VerticalArrangement2 and reset it to gray, the red border at the cell that activates that action.

you are make things complicated.
I have an easy way, you just need a boolean variable to remember if any label is highlighted.

The story of my life starts with a complicated approach to thinking. But in the end, it will be simple.

In just two weeks, from knowing nothing about AI2, with the help of @TIMAI2 , @ABG, and @Kevinkun, of course. I'm privileged to have those masters in AI2. I want to thank you again for your time.:smiling_face_with_three_hearts: By the way, it is working as I expected, like a charm.

Back to my lack of understanding...

I want to customize that button, if I enable any of that block, does nothing about what I want. I don't understand what I do wrong. Width and height are working, my logic says that it must work, and the border, background, colors, and so on...

Where did I fail?!

I discovered the fact that when I use the "y" as a variable it modify backward (borders in the cell), but when I use the "button" as a variable, it crashes the companion!!!

I think the Kevin extension may not be designed for already clickable elements that already exist in AI2 basic?! I read in some post here about checkboxes.

I must use the AI2 included buttons? There is no problem with this.

It crashes the same as with the dynamic button, Something I did wrong. but I don't know what.

to find out what happens, use logcat

Taifun