Thread: Beep & Time
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Faraz A. Qureshi Faraz A. Qureshi is offline
external usenet poster
 
Posts: 211
Default Beep & Time

Thanx Michelle!

That was excellent! However, what's the logic of using BYTE???

--
Best Regards,

Faraz


"Michelle" wrote:

Another 'dodgy' option is to get it to run a loop with nothing in it lts of
times, so that it takes up the time you want.

Sub test()
Dim x As Byte, y As Long
For x = 1 To 10
Beep
For y = 1 To 50000000
Next y
Next x
End Sub


This will run at different speeds on different machines though.

It's a bodged workaround but it might do what you want

M


"Faraz A. Qureshi" wrote in
message ...
A code like the following should play ten beeps shouldn't it?

Sub Bp()
For x = 1 To 10
Beep
Next
End Sub

How to have them played at specified intervals for example after 3/5
seconds
each?

--
Best Regards,

Faraz