Run an application when launching another app

Alligators_71 Posted messages 9 Registration date   Status Member Last intervention   -  
brucine Posted messages 24668 Registration date   Status Member Last intervention   -

Hello,

my problem is very specific. I would like to automate a task: I would like another application to launch automatically when I start a specific application without any action on my part. I tried using the task scheduler but I don't know how to use it well enough...

Thank you in advance

4 answers

mariam-j Posted messages 46 Registration date   Status Member Last intervention   37
 

Hello,
You put this in the notepad:
@echo off
start « full path of the executable«
start « full path of the other executable«
exit
You change the extension from: ".txt" to--->: ".bat"
You right-click on the file and: "run as administrator".
And that's it.

1
brucine Posted messages 24668 Registration date   Status Member Last intervention   4 142
 

Hello,

What's the relation with accounting?

The task scheduler cannot do that; it would require executing the task "on an event," which only exists for certain Windows services and provided that you know the identifier of the concerned event.

However, it can be easily obtained indirectly by a batch that will contain 2 start lines (the path of my application), and then we will launch both applications by running this batch instead of launching the applications directly.

0
Alligators_71 Posted messages 9 Registration date   Status Member Last intervention   1
 

how would that work?

0
Alligators_71 Posted messages 9 Registration date   Status Member Last intervention   1
 

Hello, thank you for your response. Here is the location of my 2 files: does this give that?

@echo off
start C:\Riot Games\League of Legends\LeagueClient
start C:\Program Files (x86)\Overwolf\OverwolfLauncher
exit

0
brucine Posted messages 24668 Registration date   Status Member Last intervention   4 142
 

No.

You need to run the perfectly designated executable, I suppose that's exe: LeagueClient.exe

As soon as there's a special character in the path (here the space), this path must be in quotes:

start "C:\Program Files (x86)\Overwolf\OverwolfLauncher.exe"

exit is not necessary, it can be replaced by nothing or by :eof
.bat is not harmful but is a remnant of Win9X, currently we save as toto.cmd

I don't understand anything about games and I do everything to make it last, but assuming that one of the programs needs to be launched and executed for the other to work, you need to allow it some delay.

So I will intersperse after the first line:

TIMEOUT /T 30 (so 30 seconds in the chosen example).

Next time, please kindly put your question in the dedicated section, and not randomly anywhere...

0
Alligators_71 Posted messages 9 Registration date   Status Member Last intervention   1 > brucine Posted messages 24668 Registration date   Status Member Last intervention  
 

Good evening, placing this discussion in accounting is a mistake, it was not intentional...

For the next steps, it still doesn't work

0
brucine Posted messages 24668 Registration date   Status Member Last intervention   4 142 > Alligators_71 Posted messages 9 Registration date   Status Member Last intervention  
 

Provide the syntax of the commands you wrote

0
brucine Posted messages 24668 Registration date   Status Member Last intervention   4 142 > brucine Posted messages 24668 Registration date   Status Member Last intervention  
 

That said, it's likely that you didn't read carefully and forgot the quotation marks, otherwise there would be no reason for C:\Riot to be individualized in the response.

0
mariam-j Posted messages 46 Registration date   Status Member Last intervention   37
 

Are there any extensions to your files? (".exe"; ".txt"; ".pdf" ...etc)

It's the executables (".exe") that need to be run.

0
Alligators_71 Posted messages 9 Registration date   Status Member Last intervention   1
 

they are both exe but it doesn't work

0