Go Back   PCMech Forums > Windows Support > Windows Tips, Tricks, and Tweaks

Need Some Help? Type Your Keywords Here:

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Old 05-26-2005, 10:25 PM   #1
Member (7 bit)
 
Join Date: May 2002
Location: Jacksonville, Florida
Posts: 103
Send a message via ICQ to JagZone Send a message via AIM to JagZone Send a message via Yahoo to JagZone
Creating Sleep Timer for Applications

I know there's gotta be someway of doing this but I want to create something like a sleep timer on a clock radio but for applications such as WMP or IE. I use a streaming radio feed off the internet but when I go to sleep at night I want it to shut down IE after a certain period of time so the music doesn't play all night.

Anyone know about doing this.

BTW...not sure if this is right forum or not for this..sry mods
JagZone is offline   Reply With Quote
Old 05-26-2005, 11:15 PM   #2
glc
Forum Administrator
Staff
Premium Member
 
glc's Avatar
 
Join Date: May 2000
Location: Joplin MO
Posts: 37,791
You could probably write a simple batch file or something, and put it into Scheduled Tasks.
glc is online now   Reply With Quote
Old 05-27-2005, 09:32 AM   #3
Member (7 bit)
 
Join Date: May 2002
Location: Jacksonville, Florida
Posts: 103
Send a message via ICQ to JagZone Send a message via AIM to JagZone Send a message via Yahoo to JagZone
That's what I was figuring would be the best way but I have no clue where to even start on that kind of thing
JagZone is offline   Reply With Quote
Old 05-27-2005, 11:44 AM   #4
glc
Forum Administrator
Staff
Premium Member
 
glc's Avatar
 
Join Date: May 2000
Location: Joplin MO
Posts: 37,791
This may help:

http://help.lockergnome.com/lofivers...hp/t33267.html

This is for a shutdown script - it will shut down your computer in an orderly fashion.
glc is online now   Reply With Quote
Old 05-27-2005, 12:10 PM   #5
Professional gadfly
 
doctorgonzo's Avatar
 
Join Date: Jan 2002
Location: Minneapolis, MN
Posts: 6,364
Send a message via MSN to doctorgonzo
Create a new text file and name it something like "Alarm.bat"...it doesn't matter as long as it has a .bat extension. Open the file in Notepad and put this line in:

"C:\Program Files\Windows Media Player\wmplayer.exe" /prefetch:1 "http://www.npr.org/dmg/dmg.php?getProgramStream=true&NPRMediaPref=WM"

Of course, use the http link for the stream you want to listen to. Save the file and exit.

Go to Control Panel, then Scheduled Tasks, then Add a new task. Select the batch file you just created and set the time and frequency you want. That's it!
doctorgonzo is offline   Reply With Quote
Old 05-27-2005, 02:52 PM   #6
glc
Forum Administrator
Staff
Premium Member
 
glc's Avatar
 
Join Date: May 2000
Location: Joplin MO
Posts: 37,791
That looks to me like it will *start* WMP, I think this person wants something to shut it OFF.
glc is online now   Reply With Quote
Old 05-27-2005, 02:59 PM   #7
Professional gadfly
 
doctorgonzo's Avatar
 
Join Date: Jan 2002
Location: Minneapolis, MN
Posts: 6,364
Send a message via MSN to doctorgonzo
Ah, I see, I was reading it completely backwards.

Doing this in Windows is a lot harder than Linux, where you could use a cron job to grep the list of running processes and kill it from there. However, I found this utility called Task Kill that might do the trick. You can do the same thing with the batch file, and kill Windows Media Player at a specific time using the utility.
doctorgonzo is offline   Reply With Quote
Old 05-28-2005, 10:02 PM   #8
Member (10 bit)
 
Join Date: Jan 2002
Location: Oregon Coast
Posts: 768
Microsoft"s "Plus! Digital Media Edition" comes with a timer for WMP to shut it off and turn on. Whole package is 19.95 from Microsoft , lots of other features included too.
jamesrpm is offline   Reply With Quote
Old 10-24-2005, 05:57 PM   #9
Member (7 bit)
 
Join Date: May 2002
Location: Jacksonville, Florida
Posts: 103
Send a message via ICQ to JagZone Send a message via AIM to JagZone Send a message via Yahoo to JagZone
Just wanted to follow up on this. The information Doctorgonzo posted worked perfectly. I used tskill.exe and just set it up as a scheduled task. The scheduled task line read:

C:\WINDOWS\system32\tskill.exe firefox

Because now the music is playing streaming through the webrowser. You can't put the .exe extension on though just the process name without the extension.

Then I simply set the task up to run when the computer is idle for 100 minutes. Works like a charm. Just an FYI for anyone else wanting to do this. You can even set it up to kill Windows media player by using

C:\WINDOWS\system32\tskill.exe wmplayer
JagZone is offline   Reply With Quote
Reply

Bookmarks

Still Need Help? Type Your Keywords Here:


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 02:18 PM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
SEO by vBSEO 3.6.0 PL2