+ Reply to Thread
Results 1 to 12 of 12

background music to a spreadsheet?

Hybrid View

  1. #1
    Registered User
    Join Date
    01-16-2008
    Posts
    32
    o sorry, i was being clueless.. mm the music will be just an mp3 file. (sorry no idea about terms - just a standard music file) hope that is the correct answer??

  2. #2
    Forum Expert dominicb's Avatar
    Join Date
    01-25-2005
    Location
    Lancashire, England
    MS-Off Ver
    MS Office 2000, 2003, 2007 & 2016 365
    Posts
    4,867

    Smile

    Hi penzer

    OK, so you're trying to play an MP3 file from within Excel - this is particularly difficult. I've never actually tried it myself, and might have a go next week when I have some time, but you might like to have a look at these two threads that give some instruction on how to do it :
    http://www.mrexcel.com/forum/showthread.php?t=293213
    http://www.mrexcel.com/forum/showthread.php?t=167671
    ...but be warned it is heavy going.

    However, if you can convert your tracks to .wav (search Google for a free tool) then the task becomes much easier - use this code :

    Private Declare Function PlaySound Lib "winmm.dll" Alias "PlaySoundA" (ByVal lpszName As String, ByVal hModule As Long, ByVal dwFlags As Long) As Long
    
    Const SND_SYNC = &H0
    Const SND_ASYNC = &H1
    Const SND_FILENAME = &H20000
    
    Sub PlayMyWAV()
    Call PlaySound("C:/MyWavFile.wav", 0&, SND_ASYNC Or SND_FILENAME)
    End Sub
    Just run the code PlayMyWAV to kick the whole thing off.

    HTH

    DominicB
    Please familiarise yourself with the rules before posting. You can find them here.

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689
    If I wanted to listen to music while using Excel, I'd use an MP3 player.

    If I wanted to dazzle other people by playing music when they opened one of my spreadsheets, I would first make sure that the spreadsheet itself was so awe-inspiring in its appearance, so startling in its clarity, so intuitive in its use, so amazing in its utility, so ... ... ... that it lacked only a symphony to make it a completely transcendental experience. And since my next spreadsheet that has all those attributes will also be my first, it might be some time before I do. Just a thought ...

    In the meantime, you could do Tools > Options > General, and check Provide feedback with sound.

  4. #4
    Registered User
    Join Date
    01-16-2008
    Posts
    32
    Quote Originally Posted by shg
    If I wanted to listen to music while using Excel, I'd use an MP3 player.

    If I wanted to dazzle other people by playing music when they opened one of my spreadsheets, I would first make sure that the spreadsheet itself was so awe-inspiring in its appearance, so startling in its clarity, so intuitive in its use, so amazing in its utility, so ... ... ... that it lacked only a symphony to make it a completely transcendental experience. And since my next spreadsheet that has all those attributes will also be my first, it might be some time before I do. Just a thought ...

    In the meantime, you could do Tools > Options > General, and check Provide feedback with sound.

    sorry i dont really understand what point you are marking but cheers for that tip iil give it a go , also thanks for the script ,, iil try and convert my spreadsheet is not going to be that good it just has to show as many media variables as possible. (i.t course)

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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