Click here to Skip to main content
15,884,176 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Playing Sound with Managed C++ .NET Pin
allenmpcx3-Aug-05 15:22
allenmpcx3-Aug-05 15:22 
GeneralRe: Playing Sound with Managed C++ .NET Pin
Christian Graus3-Aug-05 15:23
protectorChristian Graus3-Aug-05 15:23 
GeneralRe: Playing Sound with Managed C++ .NET Pin
allenmpcx3-Aug-05 15:25
allenmpcx3-Aug-05 15:25 
GeneralRe: Playing Sound with Managed C++ .NET Pin
Christian Graus3-Aug-05 16:11
protectorChristian Graus3-Aug-05 16:11 
GeneralRe: Playing Sound with Managed C++ .NET Pin
allenmpcx3-Aug-05 16:20
allenmpcx3-Aug-05 16:20 
GeneralRe: Playing Sound with Managed C++ .NET Pin
Christian Graus3-Aug-05 16:24
protectorChristian Graus3-Aug-05 16:24 
GeneralRe: Playing Sound with Managed C++ .NET Pin
Trollslayer3-Aug-05 22:05
mentorTrollslayer3-Aug-05 22:05 
GeneralRe: Playing Sound with Managed C++ .NET Pin
GKarRacer5-Aug-05 9:52
GKarRacer5-Aug-05 9:52 
To answer the original question (at least for C++):

If all you want to do is play wave files, then you can simply call the PlaySound function. If you need to anything more sophisticated like mixing sound files together, etc. then you'll probably need DirectX. But for basic wave files, the PlaySound function is very easy.

From regular C++ (someone else will have to help with proper imports for the managed environment):

#include "mmsystem.h"
#pragma comment( lib, "winnmm.lib" )

void SomeFunction()
{
    PlaySound( szSoundFileName, NULL, SND_FILENAME | SND_ASYNC | SND_NOWAIT );
}

Questionhow to draw a line on a CStatic control Pin
ginognaus3-Aug-05 13:58
ginognaus3-Aug-05 13:58 
AnswerRe: how to draw a line on a CStatic control Pin
Christian Graus3-Aug-05 14:01
protectorChristian Graus3-Aug-05 14:01 
AnswerRe: how to draw a line on a CStatic control Pin
Member 4733303-Aug-05 19:26
Member 4733303-Aug-05 19:26 
AnswerRe: how to draw a line on a CStatic control Pin
Nishad S3-Aug-05 20:20
Nishad S3-Aug-05 20:20 
GeneralRe: how to draw a line on a CStatic control Pin
ginognaus3-Aug-05 21:14
ginognaus3-Aug-05 21:14 
GeneralRe: how to draw a line on a CStatic control Pin
Anonymous3-Aug-05 23:39
Anonymous3-Aug-05 23:39 
AnswerRe: how to draw a line on a CStatic control Pin
ThatsAlok5-Aug-05 3:28
ThatsAlok5-Aug-05 3:28 
GeneralPlz help with CLongBinary Pin
Razi Al-Sayed3-Aug-05 13:50
Razi Al-Sayed3-Aug-05 13:50 
GeneralRe: Plz help with CLongBinary Pin
Christian Graus3-Aug-05 14:03
protectorChristian Graus3-Aug-05 14:03 
GeneralInvoke rename Pin
Gurra_Koo3-Aug-05 9:58
Gurra_Koo3-Aug-05 9:58 
GeneralRe: Invoke rename Pin
David Crow3-Aug-05 10:16
David Crow3-Aug-05 10:16 
GeneralRe: Invoke rename Pin
Gurra_Koo3-Aug-05 10:19
Gurra_Koo3-Aug-05 10:19 
QuestionHow to design a 2D Map designer in a worskpace MDI application Pin
bouli3-Aug-05 9:30
bouli3-Aug-05 9:30 
AnswerRe: How to design a 2D Map designer in a worskpace MDI application Pin
Blake Miller3-Aug-05 9:41
Blake Miller3-Aug-05 9:41 
GeneralRe: How to design a 2D Map designer in a worskpace MDI application Pin
bouli3-Aug-05 9:44
bouli3-Aug-05 9:44 
GeneralRe: How to design a 2D Map designer in a worskpace MDI application Pin
Blake Miller3-Aug-05 10:26
Blake Miller3-Aug-05 10:26 
AnswerRe: How to design a 2D Map designer in a worskpace MDI application Pin
Graham Bradshaw3-Aug-05 13:00
Graham Bradshaw3-Aug-05 13:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.