Reference Embedded WAV file

  • Thread starter Thread starter AC
  • Start date Start date
A

AC

I am able to add a WAV file to the VB.NET project.

BuildAction = Content (properties window)

How do I reference the embedded WAV file so it's part of the EXE when
compiled ? I'm trying to avoid the : rc = PlaySound(FileName, 0,
SND_NOWAIT) scenerio. I'd prefer to use the wav file much like a class
(which cannot be changed by the user)

Thanks,
AC
 
AC said:
BuildAction = Content (properties window)

'Content' doesn't embed the wave file. I assume you use 'Embedded
resource'.
How do I reference the embedded WAV file so it's part of the EXE when
compiled ? I'm trying to avoid the : rc = PlaySound(FileName, 0,
SND_NOWAIT) scenerio. I'd prefer to use the wav file much like a class
(which cannot be changed by the user)

<URL:http://dotnet.mvps.org/dotnet/code/misc/#PlaySound>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top