Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: Creating a batch file to open programs in order  (Read 5228 times)

0 Members and 1 Guest are viewing this topic.

willfred

  • Guest
Creating a batch file to open programs in order
« on: July 21, 2011, 05:37:55 AM »
Hello everyone,
i´m building a flight simulator, and wanted for the computer to open programs automatically and seguentially, when the computer starts. I´ve created a file that opens the programs, but all at once.
I need to open FSX.exe first, wait for it to load, then open the Simkits software, and then the Instructor software.
So, is there a command where I would open FSX and wait 1 minute for it to load, and open the second file, and so on?

I saw in a website this comand, but cant seem to get it to work .

for /L %%I in (1,1,60) do start "C:\Arquivos de Programa\Mozilla Firefox" firefox.exe

Thank you in advance

DaveLembke



    Sage
  • Thanked: 662
  • Certifications: List
  • Computer: Specs
  • Experience: Expert
  • OS: Windows 10
Re: Creating a batch file to open programs in order
« Reply #1 on: July 21, 2011, 01:12:06 PM »
I have seen ways to do this in other than batch like C++, but in batch the problem you are probably facing is that until firefox closes does it step to launch the next application right?

Nathansswell



    Rookie

    Thanked: 1
    • Yes
    • I make music!
  • Certifications: List
  • Computer: Specs
  • Experience: Beginner
  • OS: Windows 8
Re: Creating a batch file to open programs in order
« Reply #2 on: November 21, 2011, 11:53:20 PM »
You could use the ping command and set the time it takes for it to load:

ping 1.1.1.1 -n 1 -w 10000 >nul

10000=10 seconds

Good luck, hope it works.

skorpio07



    Rookie
  • sniff sniff sniff
    • Fantasea Grafix
  • Computer: Specs
  • Experience: Guru
  • OS: Other
Re: Creating a batch file to open programs in order
« Reply #3 on: December 15, 2011, 01:32:35 PM »
would this work as well?
 
ping localhost -n 60 > nul
 
that should do it in one minute increments, create a loop do to more than once

Salmon Trout

  • Guest
Re: Creating a batch file to open programs in order
« Reply #4 on: December 15, 2011, 01:46:04 PM »
This thread died in July 2011.

skorpio07



    Rookie
  • sniff sniff sniff
    • Fantasea Grafix
  • Computer: Specs
  • Experience: Guru
  • OS: Other
Re: Creating a batch file to open programs in order
« Reply #5 on: December 15, 2011, 02:44:27 PM »
apparently so did i  :o
 
but i get the drift, i will move on to another forum so as not to offend your turf

BC_Programmer


    Mastermind
  • Typing is no substitute for thinking.
  • Thanked: 1140
    • Yes
    • Yes
    • BC-Programming.com
  • Certifications: List
  • Computer: Specs
  • Experience: Beginner
  • OS: Windows 11
Re: Creating a batch file to open programs in order
« Reply #6 on: December 15, 2011, 03:05:36 PM »
apparently so did i  :o
 
but i get the drift, i will move on to another forum so as not to offend your turf

It's nothing about turf. It's about thread necromancy, which is frowned upon by most members of any forum. (unless it's the Original Poster)
I was trying to dereference Null Pointers before it was cool.

Squashman



    Specialist
  • Thanked: 134
  • Experience: Experienced
  • OS: Other
Re: Creating a batch file to open programs in order
« Reply #7 on: December 15, 2011, 04:33:33 PM »
I agree. Leave a thread alone if the original poster has not come back.  On most of the forums I contribute on if  a new user posts a question I usually answer back with a feeler question to see if they are going to come back.  I don't like wasting my time writing a script if they are never going to come back.