PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV 2024 → Looper in WB19
Looper in WB19
Débuté par André Labuschagné, 01 oct. 2015 08:21 - 4 réponses
Posté le 01 octobre 2015 - 08:21
Hi All

This is probably one serious brain fart and I am hoping someone is going to point out the obvious.

I have a checkbox control in a looper on a WB19 page. When the user clicks on the checkbox I want it to switch from off to on and vice versa. That part I get as I have done this extensively in WM. The only server code segments I can see is Initialization and Row Display for the Looper and Initialization and Whenever Modified for the static control that holds the variable. No matter where I put the code all rows get checked or unchecked. Browser code cannot address elements in a looper on a page. I have even tried Ajax without any success.

There really has to be a simple way to do this. Any ideas?

Cheers
André
Posté le 01 octobre 2015 - 13:10
Hi André,

What do want to switch on/off?
The checkbox "whenever modified" server code will do whatever you want.
And in WB 19 you need to use attributes for the looper elements.

Regards,
Piet
Posté le 05 octobre 2015 - 09:25
Hi

Cannot get this right - used buttons that get triggered and all manner of jumping though hoops. The page gets refreshed and the selection removed.

Cheers
André
Posté le 05 octobre 2015 - 10:24
Hi André,

Set the checkbox code to Ajax, that way the page will not be refreshed.

Regards,
Piet
Posté le 05 octobre 2015 - 16:20
Hi Piet

Tried that with a number of combinations. Did not work. I am going to revisit this and will post if I find a solution.

Cheers
Andre