#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 13
Default Alarm

Could someone help me, please?

Is there any function in excel which would be able to play some sound alarm
if the value in selected cell is for example higher than 10?

Thanks in advance

Jiri
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 698
Default Alarm

Try this in the sheet module. Not sure where I got it, I did not write it,
I just made small adjustments to it.. Change Range(A5) and cell value to
suit.

Private Declare Function Beep Lib _
"kernel32" (ByVal dwFreq As Long, _
ByVal dwDuration As Long) As Long

Private Sub Worksheet_Change(ByVal Target As Range)
Dim frequency As Long
Dim duration As Long
If Target < Range("A5") Then Exit Sub
If Target.Value 50 Then
frequency = 4160
duration = 1500
Call Beep(frequency, duration)
End If
End Sub

HTH
Regards,
Howard

"Tomas" wrote in message
...
Could someone help me, please?

Is there any function in excel which would be able to play some sound
alarm
if the value in selected cell is for example higher than 10?

Thanks in advance

Jiri



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,836
Default Alarm

This should give you some ideas:
http://j-walk.com/ss/excel/tips/tip87.htm
http://www.vbaexpress.com/kb/getarticle.php?kb_id=161

HTH,
Ryan--

--
Ryan---
If this information was helpful, please indicate this by clicking ''Yes''.


"Tomas" wrote:

Could someone help me, please?

Is there any function in excel which would be able to play some sound alarm
if the value in selected cell is for example higher than 10?

Thanks in advance

Jiri

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 698
Default Alarm

I offered a solution that would beep if a value over 50 was entered in a
specific cell. (Although I don't see it as of yet) I reread your post and
you want an alarm if the SELECTED cell value is over 10. Try this.

Option Explicit

Private Declare Function Beep Lib _
"kernel32" (ByVal dwFreq As Long, _
ByVal dwDuration As Long) As Long

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim frequency As Long
Dim duration As Long
If Target.Count < 1 Then Exit Sub
If Target.Value 10 Then
frequency = 4160
duration = 1500
Call Beep(frequency, duration)
End If
End Sub

HTH
Regards,
Howard

"Tomas" wrote in message
...
Could someone help me, please?

Is there any function in excel which would be able to play some sound
alarm
if the value in selected cell is for example higher than 10?

Thanks in advance

Jiri



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
FLASH ALARM osama amer Excel Discussion (Misc queries) 1 August 28th 06 12:10 PM
FLASH ALARM osama amer Excel Discussion (Misc queries) 0 August 28th 06 10:30 AM
Schedule Alarm Richard Excel Discussion (Misc queries) 0 October 14th 05 01:54 PM
Alarm Clock? Rodney New Users to Excel 4 May 13th 05 01:54 AM
How can a set an alarm in Excel? Laura Excel Discussion (Misc queries) 0 February 16th 05 10:27 PM


All times are GMT +1. The time now is 05:58 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"