PDA

View Full Version : pause audio background


MeX23
04-01-2005, 08:58 AM
Hi, I have a button, when I click on it a video begin and the music background will paused! I want the music background will played when i close the video!
how I can do it?

thanks, I'm sorry for my english...

rhosk
04-01-2005, 09:03 AM
Take a look at your actions in the Video Object (assuming this is what you're using). On stop, pause, finish -> you could restart your background audio there.

MeX23
04-01-2005, 09:16 AM
I have this code:

File.Open("AutoPlay\\Videos\\2x02.avi", "AutoPlay\\Videos", SW_SHOWNORMAL);
Audio.Pause(CHANNEL_BACKGROUND);

rhosk
04-01-2005, 09:25 AM
Sheesh, you had to make it hard :D

The only thing I can think of is to get the title of the window and monitor it for close, then start your bg audio when the window exits.

Actually, thinking about it, there's really no way to achieve this as the avi opening like that can open with many different players. Why not use the Video Object? Your project and all, just curious. More control that way.

TJ_Tigger
04-01-2005, 09:39 AM
I would suggest that you use the internal video object in AMS due to the fact that you will have more control over what happens with the video. You can look for the active windows and find the title of your video as it is being played and monitor the window to see when it is closed. The problem being you would have to check to see what the title windows look like for WMP - several different versions, Real Player, WMP Classic and what ever else someone might be using as a video player.

Tigg