Updating TMediaPlayer buttons

Giganews Newsgroups
Subject:Updating TMediaPlayer buttons
Posted by: Harold (h.holmes@n.o.spam.lincolnbeach.com)
Date:Mon, 30 Jan 2006

If I record a wave, then press stop and have it call .rewind and click play
it plays the new wave audio but after the wave is done the buttons do not
reset themselves.

I've tried this in the OnNotify event and it does run through the code but
the button appearance does not get updated:

if waveplayer.NotifyValue=nvSuccessful then
  begin
  WavePlayer.stop;
  waveplayer.rewind;
  WavePlayer.enabledbuttons:=[btPlay,btRecord];
  Waveplayer.update;
  Waveplayer.refresh;
  end;

What else should I be looking at?

--
Best regards,
Harold

Replies