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

Author Topic: Make batch files run invisible  (Read 3636 times)

0 Members and 1 Guest are viewing this topic.

wtfpyuo

  • Guest
Make batch files run invisible
« on: May 10, 2007, 12:42:40 PM »
how do you make a batch file that after it opens it will  carry out the commands invisibly?
Thank you

jsheehan223

  • Guest
Re: Make batch files run invisible
« Reply #1 on: May 10, 2007, 01:18:43 PM »
Best way that I've seen is to create a shortcut to the batch file and have the shortcut run minimized.  It will open a command window, but it will run minimized in the task bar.  If it runs quickly, it's practically invisible.

GuruGary



    Adviser
    Re: Make batch files run invisible
    « Reply #2 on: May 10, 2007, 07:12:34 PM »
    Do you want to hide the output of the batch file, or hide the whole window?  Most commands allow you to redirect the output using the greater than symbol ">".  If your batch file is small enough just redirect everything to NUL.  Otherwise you could call your batch file with another batch file redirecting the output to NUL.

    Example 1: You have a batch file called script.bat.  Let's say script.bat runs the IPCONFIG command but you want to hide the output.  You could change the IPCONFIG line to:
    Code: [Select]
    ipconfig >NUL
    Example 2: You have a batch file called script.bat (same as the example above).  But if you don't want to edit script.bat or if it is really long and you don't want to redirect each line to NUL, then create a new batch file called invis.bat (or whatever you want to call it) that contains:
    Code: [Select]
    @echo off
    call script.bat >NUL

    CBMatt

    • Mod & Malware Specialist


    • Prodigy

    • Sad and lonely...and loving every minute of it.
    • Thanked: 167
      • Yes
    • Experience: Experienced
    • OS: Windows 7
    Re: Make batch files run invisible
    « Reply #3 on: May 10, 2007, 08:11:51 PM »
    I can see this sort of informating getting into the wrong hands...
    Quote
    An undefined problem has an infinite number of solutions.
    —Robert A. Humphrey

    Carbon Dudeoxide

    • Global Moderator

    • Mastermind
    • Thanked: 169
      • Yes
      • Yes
      • Yes
    • Certifications: List
    • Experience: Guru
    • OS: Mac OS
    Re: Make batch files run invisible
    « Reply #4 on: May 10, 2007, 08:14:07 PM »
    I can see this sort of informating getting into the wrong hands...
    Same...this information can be used for.....odd purposes...

    wtfpyuo

    • Guest
    Re: Make batch files run invisible
    « Reply #5 on: May 10, 2007, 11:22:40 PM »
    Thank you