+ Reply to Thread
Results 1 to 24 of 24

Sound Alert as a cell value changes

  1. #1
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Sound Alert as a cell value changes

    I simply want to hear a sound when a cell value changes ("S80"). No matter what the value of it is, whenever this cell changes its value, I want it to alarm. I searched the web for many solutions, including http://j-walk.com/ss/excel/tips/tip87.htm, but most of them are giving examples of Beep or .wav alert in response to a particular value (> 1000) or a certain threshold.

    All I need is to know while working on my spreadsheet whether that cell ("S80") changes or not by hearing the alarm. I have been looking at Beep function, and it seems to work fine, except that it always alarms with disregard to what the cell value is.


    Any help is greatly appreciated as I have been researching this for days now!

    Thanks,

  2. #2
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    Just wanted to know, is there any formula in cell S80. If so, please share formula.

    Thanks
    Like my answer, then click * below

  3. #3
    Forum Expert
    Join Date
    01-23-2013
    Location
    USA
    MS-Off Ver
    Microsoft 365 aka Office 365
    Posts
    3,863

    Re: Sound Alert as a cell value changes

    Hi mrdog,

    Try putting the following code in the 'Sheet1' module (or the module for whatever the Sheet Name you are using is):
    Please Login or Register  to view this content.
    Lewis

  4. #4
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    Thanks Lewis,

    But, what if, the cell contains some formula...

    Thanks

  5. #5
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    If S80 is not a manual entry, then we need to ask for the formula using in S80.

    Then we will be defining a UDF for that formula along with the "BEEP" code. And new UDF will be used in the S80.

    So, when ever there is any change in the dependents of S80, then the UDF will re-run the code which already have "BEEP" statement so it will play the sound...

    So, Mr. Dog, could you please help me with the logic or formula used in the "S80"...

    Thanks

  6. #6
    Registered User
    Join Date
    06-09-2011
    Location
    Newcastle, Australia
    MS-Off Ver
    2003, 2010
    Posts
    54

    Re: Sound Alert as a cell value changes

    Use Worksheet_Change(Target) event

    Please Login or Register  to view this content.
    Locate your WAV file in a static folder ... if workbook path changes the sound will still play eg, "C:\WAV_sounds"
    Last edited by GreyGhost; 02-28-2014 at 08:40 AM.

  7. #7
    Forum Expert
    Join Date
    01-23-2013
    Location
    USA
    MS-Off Ver
    Microsoft 365 aka Office 365
    Posts
    3,863

    Re: Sound Alert as a cell value changes

    Great call satabp. I forgot about changing by formula. It then gets a little more complicated. Assuming cell 'S80' is on 'Sheet1.:

    In an Ordinary Module Such as Module1, Put:
    Please Login or Register  to view this content.
    In ThisWorkbook you put:
    Please Login or Register  to view this content.
    Put the following code in the 'Sheet1' module:
    Please Login or Register  to view this content.
    NOTE: Without the initialization code in 'Workbook_Open(), the 'Beep' would sound the first time a 'Calculate' event occurred in 'Sheet1', even if it didn't affect cell 'S80'.

    Lewis
    Last edited by LJMetzger; 02-28-2014 at 08:54 AM. Reason: Added initialization NOTE.

  8. #8
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    Yes. S80 contains a SUM formula.

  9. #9
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    can you please provide the formula given s80

  10. #10
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    use the following code in Module 1

    and use forumula Add() in S80.

    Syntax: Add(Range)

    Please Login or Register  to view this content.

  11. #11
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    This can be used any where in your file/sheet...

    It will be make a beep sound, whenever there is any change in the value of the cell contain ADD()

  12. #12
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    satabp, I tried this method before, and I just did again now. I beeps every time I enter a number ANYWHERE in the worksheet. Not necessarily affecting the value of S80 (now S90).

    I have a set of individual cells containing certain numbers in column S: S30, S34, S56, ..S89. The sum of these numbers are in S90. The numbers in the individual S cells change according to certain categories. Which in turn would change the sum on S90. The reason why I need to hear the beep is because if I were to enter a category that is not included within the sum of the individual cells, the sum will not be affected and wouldn't hear the beep, which tells me that I need to add a category.

    S90 contains: "=SUM(S4,S6,S10,S13,S21,S40,S46,S50,S56,S61,S71,S76,S80,S67,S88,S54)"

    I tried using most posts in this thread, but I keep getting an error message. I don't have a huge experience with excel, and I would greatly appreciate a simplified way of doing this.

    Thank you all for the help

  13. #13
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    Hi,

    Copy the following code in one of the module..

    Please Login or Register  to view this content.

    Step 1. Just select the all your cells to be included in the formula.. (Multiple cell selection can be done by holding the "Ctrl" key in keyboard)

    Step 2: Once you selected all the required cells, just go to Address/Formula Bar. Left side just type the name as "MyRange" and press enter
    (or) Press ALT I + N + D, then click on button "New" on the dialog box. And give the name as "MyRange" then click ok.

    Step 3: Go to S90 and enter the formula as "=add(MyRange)"

    Now, try to change the values of the cells in the range you selected.

  14. #14
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    I'm not sure why but I'm still having the same issue!
    I'm starting a new spreadsheet to see if the problem is related to sheet im working on. I have a feeling that it is since I am using a large numbers of formulas that are associated with S90.
    I will let you know how it goes..

    Quote Originally Posted by satabp View Post
    Hi,

    Copy the following code in one of the module..

    Please Login or Register  to view this content.

    Step 1. Just select the all your cells to be included in the formula.. (Multiple cell selection can be done by holding the "Ctrl" key in keyboard)

    Step 2: Once you selected all the required cells, just go to Address/Formula Bar. Left side just type the name as "MyRange" and press enter
    (or) Press ALT I + N + D, then click on button "New" on the dialog box. And give the name as "MyRange" then click ok.

    Step 3: Go to S90 and enter the formula as "=add(MyRange)"

    Now, try to change the values of the cells in the range you selected.

  15. #15
    Forum Expert
    Join Date
    01-23-2013
    Location
    USA
    MS-Off Ver
    Microsoft 365 aka Office 365
    Posts
    3,863

    Re: Sound Alert as a cell value changes

    satabp: You may want to change your function to replace 'Integer' with 'Variant', since you do not know what type of data mrdog is using.

    mrdog: If you're still having problems, post a sample workbook. It just needs the sheet with the cell in it, and the cell with the formula in it. The rest of the workbook can be blank if you want. That will make it easier for us to post a solution that you can try out.

    Lewis

  16. #16
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    Hi,

    I have added the same in the attached blank file... in sheet1

    check this..
    Attached Files Attached Files

  17. #17
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    LJMetzger, I am attaching a file with a note inside. The sheet should give a good view of what I am trying to do. In this worksheet though the cell that we're looking at is F13 not S90, for example sake.
    Thanks,


    Quote Originally Posted by LJMetzger View Post
    satabp: You may want to change your function to replace 'Integer' with 'Variant', since you do not know what type of data mrdog is using.

    mrdog: If you're still having problems, post a sample workbook. It just needs the sheet with the cell in it, and the cell with the formula in it. The rest of the workbook can be blank if you want. That will make it easier for us to post a solution that you can try out.

    Lewis
    Attached Files Attached Files

  18. #18
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    Satabp, your sheet works great, until I add a sumif equation. Please see attached.


    Quote Originally Posted by satabp View Post
    Hi,

    I have added the same in the attached blank file... in sheet1

    check this..
    Attached Files Attached Files

  19. #19
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    The "TGIF" data range is part of the Sumif formula, so when ever it changes, the Total formula will recalculate it...

    Hence Beep will come..
    Last edited by satabp; 02-28-2014 at 12:55 PM.

  20. #20
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    That makes sense. So even if the amount stays the same, it is still recalculating. Understood. I'm guessing there is no way around it?



    Quote Originally Posted by satabp View Post
    The "TGIF" data range is part of the Sumif formula, so when ever it changes, the Total formula will recalculate it...

    Hence Beep will come..

  21. #21
    Forum Contributor
    Join Date
    12-09-2013
    Location
    India
    MS-Off Ver
    Excel 2003
    Posts
    171

    Re: Sound Alert as a cell value changes

    I think so, but meanwhile I will research and I will post if there is any solution for this.

    If you got the solution , please mark the post as Solved and if the helpful, please click on blow * to add reputation.

    Thanks

  22. #22
    Forum Expert
    Join Date
    01-23-2013
    Location
    USA
    MS-Off Ver
    Microsoft 365 aka Office 365
    Posts
    3,863

    Re: Sound Alert as a cell value changes

    mrdog,

    Try the attached file which implements my code above in the sample file you posted.

    Lewis
    Attached Files Attached Files

  23. #23
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    Thank you so much Lewis. This is exactly what I need. Problem Solved! Your time is much appreciated. Thumbs UP!

    Quote Originally Posted by LJMetzger View Post
    mrdog,

    Try the attached file which implements my code above in the sample file you posted.

    Lewis

  24. #24
    Registered User
    Join Date
    04-24-2013
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Sound Alert as a cell value changes

    Anyone knows how to mark this problem as solved?


    Never mind.. just found it..
    Again, thanks guys for all the help!
    Last edited by mrdog; 02-28-2014 at 03:28 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] sound alert from excel
    By dan in forum Excel General
    Replies: 0
    Last Post: 06-25-2006, 10:55 PM
  2. [SOLVED] Sound alert
    By Antonio in forum Excel General
    Replies: 3
    Last Post: 05-30-2006, 02:15 PM
  3. Sound+color alert if cell changed in another worksheet
    By florinel in forum Excel General
    Replies: 0
    Last Post: 05-25-2006, 11:52 AM
  4. Sound / Audible Alert in a Woksheet ?
    By Bob Phillips in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-06-2005, 06:05 AM
  5. Sound / Audible Alert in a Woksheet ?
    By carl in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 01:05 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1