rpm_bmbz
asked on
Delphi Sounds
I want to play a 2 second *.wav file while my splash screen is loading but I cant the the mediaplayer component to work...
maybe its the loading of the program itself that jams up the *.wav file. did you try putting the mediaplayer component on another thread and running it from there?
uses MMSystem,
sndPlaysound('E:\2.wav',SN D_FILENAME +SND_RESOU RCE);
use this API to play the wav file
sndPlaysound('E:\2.wav',SN
use this API to play the wav file
have u tried
procedure TForm1.FormCreate(Sender: TObject);
begin
//MediaPlayer1.FileName:= ... (only needed if u haven't set the file in the object inspector)
MediaPlayer1.AutoRewind:=F alse;
MediaPlayer1.Open;
MediaPlayer1.Play;
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
//MediaPlayer1.FileName:= ... (only needed if u haven't set the file in the object inspector)
MediaPlayer1.AutoRewind:=F
MediaPlayer1.Open;
MediaPlayer1.Play;
end;
ASKER
I'm trying your suggestions i'll get back with you shortly
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.