BATCH ProgramminG

 

 

 

example:

 

 

md MyDir

rd MyDir

del nothing.txt

echo BlahBlah.....

pause

 

 

 

 

This code Creat a directory, and delete it ..

 

 

 

So all you need to do is just to chose What you want to put in your file ..

 

 

 

md name      //create a directory with chosen name

 

rd name      //delete a directory with chosen name, The dir most be Empty..

 

del PatchName   //Delete file/files    If your Batch file is in the same dir as the file you wanna delete, Then you only

need to write the Filename (del MyFile.exe), But if it Aint, You need to write the path to( del c:\windows\temp.dat)

 

call     //Runs an other .Bat file, And when that file is Done, Your file will continue after that call command..

 

echo HI all folks... //Print the message (HI all folks...)

 

echo off   //When you are running your .Bat file, You can see All your commands it has done on the screen, Write    echo off

so that the user can´t see what you are using for kind of commands.

 

@echo off //The '@' makes that the user can´t see what command you are using, This is only for the command with the '@'.

 

dir    //List all the files in your directory....

 

dir > info.txt    // This Command '>' Does´nt Print the output to the screen, it print it to info.txt ...

 

 

del *.exe //deletes All exe-files, u can use del c:\windows\*.exe

 

*.* //all files ..

*.dll //all dll files

e.t.c

 

copy file1 tile2 //just coping a file ...

 

if you are trying to copy a file to an excisting file, it will ask if u realy want to owerwrite it ..

But if you using:   copy a.exe b.exe /y    It won´t ask.   So just put an /y at the end ...

 

cls    //Clear the screen ...

 

pause // Print the Text   Press any key..   And waiting for A key to be pressed ...

 

 

:jupp   //creates the plase   Jupp

goto Jupp //Going to the plase Jupp

 

Example:

 

:hello

@echo hi

goto hello

 

 

 

Another example:

 

goto mio

echo This text wont be printed ....

:mio

 

 

 

 

Run a program ..

 

Just write the Program File Name.. Include Patch if it aint in the same DIr as Your batch file ..

example:

 

install.exe

//or only install, You don´t have to write .exe

 

 

START hoho.bmp   //open a document, TXT, BMP, lnk, DOC, EVERYTHING ..

 

 

 

Now, Just use your Fantasy And write Your own BATCH program .... Please E_mail me: This e-mail address is being protected from spambots. You need JavaScript enabled to view it


GSO
Written on Saturday, 03 October 2009 20:10 by GSO

Viewed 401 times so far.
Like this? Tweet it to your followers!

Rate this article

Latest articles from GSO

Latest 'tweets' from GovernmentSecurity

  • Can I get a Hoot Hoot?! #HootSuite is my number one Twitter client. http://hootsuite.com Link Friday, 06 November 2009 06:03
  • @foadah Thas what Im talking about :) Link Friday, 06 November 2009 05:58
  • #security | Don't panic over the secret copyright treaty | latest-security-news | GSO - Network Security Resources http://bit.ly/1K63Sr Link Thursday, 05 November 2009 08:01
  • #security | Which country has the most bot-infected computers? | latest-security-news | GSO - Network Security Reso... http://bit.ly/HAeG9 Link Thursday, 05 November 2009 08:01
  • #security | Backdoor access for millions of Facebook and MySpace accounts | latest-security-news | GSO - Network S... http://bit.ly/3dwnmc Link Thursday, 05 November 2009 08:01
blog comments powered by Disqus

Site Search

Sponsor Advertisements

SwiftLayer Affiliate Web Hosting

Disqus Tools