1

I want a sound to be played in a loop until an on/off button is off.

I use this code:

WHILE BTN_Bouton73..Enfoncé=1
    Son(S_chemin+"H3.wav",sonBoucle)
END

But it goes into an infinite loop!

Anonymous
  • 11,748
  • 6
  • 35
  • 57
narulamo
  • 11
  • 1
  • 4

1 Answers1

2

try with

WHILE BTN_Bouton73..Enfoncé=1
    Son(S_chemin+"H3.wav",sonBoucle)
    Multitask(-1)
END

I think you could realese button to stop

It give control back to Windows : see documentation

Renaud
  • 110
  • 1
  • 7