Wilders Security Forums  

Go Back   Wilders Security Forums > Software, Hardware and General Services > other software & services
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread
  #1  
Old November 27th, 2010, 06:49 PM
m00nbl00d m00nbl00d is online now
Incredibly Massive Poster
 
Join Date: Jan 2009
Posts: 6,462
Default Scheduling a task to start a program, when one other starts [How to?]

I've been searching the web for some info on how to schedule a task, so that when I start an application, one other I specify starts.

AFAIK, Windows 7 scheduler lacks such option, unless I totally have missed it.

So far I wasn't able to find anything that could allow me to do that.
Are you familiar with a way that could do just that?


Thanks
  #2  
Old November 27th, 2010, 08:00 PM
whitedragon551's Avatar
whitedragon551 whitedragon551 is offline
Very Frequent Poster
 
Join Date: Sep 2008
Location: USA
Posts: 2,760
Default Re: Scheduling a task to start a program, when one other starts [How to?]

In the task scheduler go to the drop down menu. Action > Create Task.
In the General tab fill it out. The trigger you want to set will be in the Actions tab and you can setup the trigger there.
__________________
|Kaspersky Anti-Virus 2013|Private Firewall|HitmanPro|MBAM|Keriver Image|WinPatrol Plus|

Looking for volunteer authors to write articles, reviews, and How-Tos. If you think you have what it takes, contact me.
|http://pc-babble.com/|
  #3  
Old November 27th, 2010, 10:56 PM
tony62's Avatar
tony62 tony62 is offline
Frequent Poster
 
Join Date: Aug 2005
Location: UK
Posts: 214
Default Re: Scheduling a task to start a program, when one other starts [How to?]

Windows batch files would be easy to use & you can schedule them. Here is an example of how to start multiple programs at once:

Code:
start /d C:\Windows\System32\calc.exe start /d “C:\Program Files\Mozilla Firefox” firefox.exe start /d “C:\Program Files\Microsoft Office\Office12″ EXCEL.EXE

Quote:
* Just open up Notepad or your favorite text editor.
* Copy the commands from above and modify them to use which ever program or Office files you want open. Make sure when you copy file and folder paths that have spaces, to use quotes.
* Then save the file with any name and a .bat extension (make sure it’s not saved using .txt as the file type extension)

More info
  #4  
Old November 29th, 2010, 10:02 PM
iceni60 iceni60 is offline
( ^o^)
 
Join Date: Jun 2004
Posts: 5,116
Default Re: Scheduling a task to start a program, when one other starts [How to?]

you could try this search 'symlinks +mklink start task when a program executes'
  #5  
Old December 1st, 2010, 03:20 AM
pajenn's Avatar
pajenn pajenn is offline
Frequent Poster
 
Join Date: Oct 2009
Posts: 598
Default Re: Scheduling a task to start a program, when one other starts [How to?]

If you have a reasonably powerful, multi-core computer, then take a look at Bill2's Process Manager. It's small, free and available as a portable application. It's mainly a process manager / smoother for adjusting process priorities and affinities (i.e. which cores a process can use), but it also has additional options for starting or killing (other) programs when a given process starts, ends or is over active or idle for too long (see pic). For example, when I start my tex editor of choice (BaKoMa TeX), Bill2 also launches a custom script of extra hotkeys and functions I have for it (I use AutoHotkey a lot).

Note: Bill2 is not resource hungry per se, but for always-on use it's meant for multi-core computers (affinity control). To get the most out of it, you should run it in learning mode for a week or two, but that can be annoying as it would ask you how to handle each new process. (Kind of like the HIPS features of a firewall).
Attached Images
 
__________________
Main machine: Samsung laptop, i7 QuadCore, 16GB RAM, SSD, USB3.0, Win7 Home Premium 64-bit (main), Mint 12.4 (linux newbie)
Software: Comodo Internet Security, KeyScrambler, Keepass w/ Dropbox to sync, Sandboxie, Peerblock, Drive Snapshot, a2cmd, EasyBCD for custom boot, AutoHotkey.

Last edited by pajenn : December 1st, 2010 at 05:58 AM.
  #6  
Old December 1st, 2010, 11:42 AM
m00nbl00d m00nbl00d is online now
Incredibly Massive Poster
 
Join Date: Jan 2009
Posts: 6,462
Default Re: Scheduling a task to start a program, when one other starts [How to?]

Quote:
Originally Posted by pajenn
If you have a reasonably powerful, multi-core computer, then take a look at Bill2's Process Manager. It's small, free and available as a portable application. It's mainly a process manager / smoother for adjusting process priorities and affinities (i.e. which cores a process can use), but it also has additional options for starting or killing (other) programs when a given process starts, ends or is over active or idle for too long (see pic). For example, when I start my tex editor of choice (BaKoMa TeX), Bill2 also launches a custom script of extra hotkeys and functions I have for it (I use AutoHotkey a lot).

Note: Bill2 is not resource hungry per se, but for always-on use it's meant for multi-core computers (affinity control). To get the most out of it, you should run it in learning mode for a week or two, but that can be annoying as it would ask you how to handle each new process. (Kind of like the HIPS features of a firewall).

Thanks!

This is what I've been looking for. I will definitely take a look at it. Thanks a lot!
  #7  
Old December 1st, 2010, 01:29 PM
Sully Sully is offline
Massive Poster
 
Join Date: Dec 2005
Posts: 3,696
Default Re: Scheduling a task to start a program, when one other starts [How to?]

I would say if all you want to do is have program B start whenever you start program A, a batch file would be the easiest. You could do this with just about any script language. If you place the batch file where program A lives, then put a shortcut to it on your desktop, you can change the icon to that of program A, and you won't notice the difference.

Sul.
__________________
I do things TO my computer, not WITH my computer.. I am a nerd.
  #8  
Old December 1st, 2010, 02:00 PM
m00nbl00d m00nbl00d is online now
Incredibly Massive Poster
 
Join Date: Jan 2009
Posts: 6,462
Default Re: Scheduling a task to start a program, when one other starts [How to?]

Quote:
Originally Posted by Sully
[...]If you place the batch file where program A lives, then put a shortcut to it on your desktop, you can change the icon to that of program A, and you won't notice the difference.

Sul.

Yes, but then I'd have to click the shortcut, as well.

I could easily create a batch file that would start both apps at the same time, and perhaps with a small lag between each other, but I was just looking and wondering what other options would be out there, regarding scheduled tasks, because Windows own scheduler lacks such an option.

I already have a batch file as you mentioned to start program A, and I could just change it to start program B as well, with a small lag between each other, but not really what I was looking for. It works fine, just not what I was aiming at.
  #9  
Old December 1st, 2010, 02:00 PM
whitedragon551's Avatar
whitedragon551 whitedragon551 is offline
Very Frequent Poster
 
Join Date: Sep 2008
Location: USA
Posts: 2,760
Default Re: Scheduling a task to start a program, when one other starts [How to?]

Quote:
Originally Posted by m00nbl00d
Yes, but then I'd have to click the shortcut, as well.

I could easily create a batch file that would start both apps at the same time, and perhaps with a small lag between each other, but I was just looking and wondering what other options would be out there, regarding scheduled tasks, because Windows own scheduler lacks such an option.

I already have a batch file as you mentioned to start program A, and I could just change it to start program B as well, with a small lag between each other, but not really what I was looking for. It works fine, just not what I was aiming at.

Actually it doesnt. I gave you instructions on how to do it.
__________________
|Kaspersky Anti-Virus 2013|Private Firewall|HitmanPro|MBAM|Keriver Image|WinPatrol Plus|

Looking for volunteer authors to write articles, reviews, and How-Tos. If you think you have what it takes, contact me.
|http://pc-babble.com/|
  #10  
Old December 1st, 2010, 02:04 PM
m00nbl00d m00nbl00d is online now
Incredibly Massive Poster
 
Join Date: Jan 2009
Posts: 6,462
Default Re: Scheduling a task to start a program, when one other starts [How to?]

Quote:
Originally Posted by whitedragon551
Actually it doesnt. I gave you instructions on how to do it.

I looked at it, and couldn't find any option that could allow me? Maybe I missed it. I'll look at it again.

-Edit-

Let me know if this is what you mean. (Bear in mind that I'm not running the English version of Windows, and therefore my translation may not be the same as the real English version words.)

I can see two more options, which are part of settings in the Actions tab:

- Add arguments (optional):
- Start with/Start in

Now, in the Settings > Program/Script, the one to be added would be program B, which would start when program A is already running. Or, do you mean the opposite, add program A?

In "Add arguments", which argument would be added to it? I'm assuming the arguments would be any that the application itself would accept when working with it using cmd line, right? How would any of its arguments allow me to start on other application?

In "Start with/Start in", following the most logical thing to me, this would be where I'd put a path, for the other application? I tried that, but it didn't start the application. I tried both approaches (first one app., then the other one).

Anyways, I believe the best option is just to create a batch/script file that would just check whether or not if program A is running, and if yes start program B, otherwise not start it.

My initial wondering had to due with Windows own scheduler, that I thought had no such options, but according to you it has, though I still couldn't make it work. I guess I'll have to take a deeper look at it, though, because now I'm interested in making it work, just for the sake of it.

Last edited by m00nbl00d : December 1st, 2010 at 02:32 PM.
  #11  
Old December 1st, 2010, 04:43 PM
Sully Sully is offline
Massive Poster
 
Join Date: Dec 2005
Posts: 3,696
Default Re: Scheduling a task to start a program, when one other starts [How to?]

I guess it depends on just what you want. I often look for the "just right" solution rather than settle for what I don't want. Often it is just to satisfy my techno thrill-o-meter.

For a batch file, here is an example for firefox and foxit (just pulling familiar apps out of thin air)

batch file would reside in firefox directory

start firefox.exe
start /d "c:\program files\foxit\foxit.exe"

* note that the /d is used to pass a directory different than the starting directory
that should mean if the batch file lives in c:\program files\mozilla, you could just type
start any_exe.exe
and as long as it is in the starting/working directory, it is good.
When needing to start programs in other directories, you would use the /d switch
(don't know why you would need that, in the "old way" you just passed a fully qualified path)

You might need to pass parameters as well, so it is helpful to take a look at how to pass those.

create a shortcut on desktop to the batch file.
change icon of the shortcut to the firefox icon.

Double click shortcut to start both programs.

Pretty much the same thing whitedragon551 said.

Perhaps you are looking for a method to monitor when a program starts, like firefox, and when it does, start another program, like foxit, if it is not already running? Then you could start this "monitoring" program on bootup and it would always do its check, like every couple seconds. You could even turn that into a service so that if the "monitor" program was terminated for some reason, it would restart itself after a timeout.

Sul.
__________________
I do things TO my computer, not WITH my computer.. I am a nerd.
 

Wilders Security Forums > Software, Hardware and General Services > other software & services « Previous Thread | Next Thread »

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 02:05 PM.


Powered by vBulletin® Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Copyright ©2002 - 2013, Wilders Security Forums