Here is the code that I used (the code stated by you in an earlier post)
Code:
#include <windows.h>
#include <cstdio>
int main(int argc, char **argv)
{
BOOL f;
f = PlaySound("c:\\Fanfare.wav", 0, SND_FILENAME);
if (!f)
printf("Error\n");
else
printf("Done!\n");
return 0;
}
Here is the compile log:
------ Build started: Project: soundtest3, Configuration: Debug Win32 ------
Compiling...
soundtest3.cpp
c:\documents and settings\mom\my documents\visual studio 2008\projects\soundtest3\soundtest3\soundtest3.cpp (7) : error C2664: 'PlaySoundW' : cannot convert parameter 1 from 'const char [15]' to 'LPCWSTR'
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
Build log was saved at "file://c:\Documents and Settings\Mom\My Documents\Visual Studio 2008\Projects\soundtest3\soundtest3\Debug\BuildLog .htm"
soundtest3 - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
I have the Fanfare.wav file on my C drive in not specific folder. I attempted to use PlaysoundA and still received errors.
Thanks Very Much