?
Solved

Play MP3 from Resource File

Posted on 2003-02-21
6
Medium Priority
?
275 Views
Last Modified: 2012-05-04
How do I play an MP3 from a resource file?
0
Comment
Question by:Produkt
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 3

Expert Comment

by:VBtom
ID: 7992664
If the MP3 has a WAV-header, you can play it with the API-function PlaySound.
0
 

Author Comment

by:Produkt
ID: 7992698
And if it doesn't?
0
 
LVL 3

Expert Comment

by:VBtom
ID: 7993451
No idea if it's possible, why do you prefer the difficult way?
If your MP3 doesn't have a wav-header, there are free tools that can add the wav-header. Or you could write a program yourself to get info from the first frameheader of the mp3 and construct a wav-header with it.
0
Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

 

Author Comment

by:Produkt
ID: 7994055
I understand how to play using sndPlaySound function, but I don't know how to play it from a resource file.
0
 
LVL 3

Accepted Solution

by:
VBtom earned 200 total points
ID: 7994193
Use Playsound, not sndPlaysound

Look here for an example: http://www.syix.com/wpsjr1/playressound.zip
0
 

Author Comment

by:Produkt
ID: 7994682
Thanks, works well.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
Simple Linear Regression

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question