Do Continuous Beeping Until a User Presses a Space Key

Guys, I’m having trouble implementing a continuous beeping for hours until someone presses a key(eg: space) in order to stop that beeping. Is there any way to implement that kind of process?


Use Send Hotkey activity


I know how to send hot key and so on. But what I am trying to do is to stop the beeping when user presses a certain key from keyboard. How to connect beeping and input from user keyboard?
eg. beeping continuously at that time, take input from user. When user presses a key, I want that beeping to be stopped.

You can check if a continous execution of:

in combination with a key trigger event will serve your needs

1 Like

could you provide an example workflow? I want to use keyboard trigger as you said. I have already tried implementing that. I have read documentation also. Somehow I don’t seem to get the expected result. Thanks for your reply.

and for beeping, I don’t use beep activity since that sound is not the one I want. So, I have written this code in invoke code activity.

Dim loopDuration As Integer = 10000 ’ 10 seconds in milliseconds
Dim startTime As DateTime = DateTime.Now

While (DateTime.Now - startTime).TotalMilliseconds < loopDuration
End While

where SoundFile is an input argument of a sound.

So, just enlighten me how to integrate this with keyboard input from user.
break that loop as soon as the user presses a key.

done in newer versions ( with the help of @k.bauer )

kindly note: hotkey trigger - key is space, so it looks like empty in the screenshot

1 Like

sorry for my late reply. Your answer worked perfectly when I added break after assign activity. Thanks for your solution. @ppr

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.