I have been learning to program in Windows using C on a PC running Windows XP and Petzold's Guide to Win32 API.
I wrote some short programs which use calls such as PlaySound (TEXT ("click.wav"), NULL, SND_FILENAME | SND_ASYNC) ; to play the sounds. All worked well.
However I decided to tidy up the sounds by placing them inside a folder called 'sounds'. I then called them using calls such as PlaySound (TEXT ("Sounds/click.wav"), NULL, SND_FILENAME | SND_ASYNC) ;
Again all worked well on Windows XP. However, I am a teacher, and at school we use Windows 92 and 98. On 95 and 98 the call to PlaySound produces silence unless I remove the sounds from the sounds folder and keep them beside the application.
It really does look better to keep all the sounds inside a sound folder. Is there any way that I can do that and have this work in XP and earlier OS?