First post!

I have two problems and I would be grateful if you could help me out with anyone of them.

First I'm trying to make a space shoot'em up game. Of course this game needs some sounds. For this I use something similar to:

[pascal]
if FileExists(ExtractFilePath(Application.ExeName)+Fi leName) then
SndPlaySound(PChar(FileName), SND_ASYNC or SND_NODEFAULT)
else
begin
{error code}
end;
[/pascal]

The problem is that after the sound is played the program freezes for a short while. That's not good and I wonder if there is any way to solve this?

Next problem is that when I use the TMediaPlayer I get an error saying that my system can't play the file (I'd post this message, but it's in Swedish). This problem occure no matter what file type I try to load. I can't figure out what the problem is, especially since it has work earlier on my computer. Anyone knows what it can be so that I at least could tell the user what causes the problem.

Thanks in advance!