+ Reply to Thread
Results 1 to 9 of 9

Sound in Excel

  1. #1
    Registered User
    Join Date
    01-12-2020
    Location
    Philadelphia, PA
    MS-Off Ver
    2016
    Posts
    97

    Sound in Excel

    I want to play a simple sound if a certain condition is met in Excel. I've gotten this to work at my work computer (Office 365) by using a simple code:
    Please Login or Register  to view this content.

    The problem is when I pull up the spreadsheet on my computer at home, I get an error and am forced to delete the code in order for the spreadsheet to work.

    If I understand correctly, this option was removed from recent versions of Excel which may be the reason, and I could use an alternative to play a .wav file, but that would require me to have a chosen .wav file in the same folder on each computer I wanted to run this on.

    Is there any other way of doing this, or am I misunderstanding something?

    Thanks!

    Moderator Comment: I have added code tags to your post. Please re-read the forum rules you agreed to when you joined and abide by them in the future.
    Last edited by alansidman; 12-27-2021 at 01:43 PM.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,935

    Re: Sound in Excel

    Maybe this will help: http://www.vbaexpress.com/kb/getarticle.php?kb_id=771
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    01-12-2020
    Location
    Philadelphia, PA
    MS-Off Ver
    2016
    Posts
    97

    Re: Sound in Excel

    Thanks.

    Stupid question though: How do I run it if a condition is met? If I use
    Please Login or Register  to view this content.
    ... I get a Syntax Error

  4. #4
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,935

    Re: Sound in Excel

    I can't test the function from the link as I can't get it to compile.

    However, with the original function, this worked for me:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,935

    Re: Sound in Excel

    Variations on a theme:

    B1: =IF(A1=1,Beepme(),"")
    B2: =IF(A2="x",Beepme(),"")
    B3: =IF(A3=A1,Beepme(),"")

  6. #6
    Registered User
    Join Date
    01-12-2020
    Location
    Philadelphia, PA
    MS-Off Ver
    2016
    Posts
    97

    Re: Sound in Excel

    Thank you!

  7. #7
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,935

    Re: Sound in Excel

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Please Login or Register  to view this content.

  8. #8
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,935

    Re: Sound in Excel

    You're welcome. Thanks for the rep.

  9. #9
    Registered User
    Join Date
    01-12-2020
    Location
    Philadelphia, PA
    MS-Off Ver
    2016
    Posts
    97

    Re: Sound in Excel

    I finally figured out the problem with using this code on my computer at home. My system says the formula must be upgraded to work with 64-bit systems (grin) Sorry!

+ 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. Sound file in Excel
    By lotusman in forum Excel General
    Replies: 5
    Last Post: 11-08-2017, 05:37 PM
  2. Sound alerm from excel
    By renuka64 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-25-2010, 07:21 PM
  3. Play sound in Excel
    By buffalobill in forum Excel General
    Replies: 4
    Last Post: 11-03-2009, 08:45 AM
  4. using sound in excel
    By vxhybrid in forum Excel General
    Replies: 6
    Last Post: 09-14-2008, 08:57 PM
  5. How to add sound to excel
    By robert111 in forum Excel General
    Replies: 4
    Last Post: 04-29-2008, 09:11 AM
  6. [SOLVED] how do i set up sound alerts on excel?
    By Anuj Dhamija in forum Excel General
    Replies: 1
    Last Post: 05-19-2006, 09:30 AM
  7. sound files in excel?
    By dkimball in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 03-24-2005, 09:06 PM

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