In this article I'll introduce you with the basic of batch file and developing of batch programmes.
Batch file programming is nothing but the windows version of Unix Shell programming. In MS-DOS, a batch file can be started from the command line by typing its name (along with any required parameters) and pressing the "enter" key. When MS-DOS loads, the file AUTOEXEC.BAT is automatically executed, so any commands that need to be run to set up the MS-DOS environment for use could be placed in this file.
Why we need batch file programs ?
When we need to execute a set of commands over and over again to perform a routine task like backup files, Del temp files, then there is very difficult to type the same set of command over and over again, batch files are used.
Creation of batch file :
Batch files are basically plain text file containing DOS command. You can edit or write your batch file with notepad or DOS editor(EDIT). Always remember that a batch file should have an extension.BAT. Firstly you have to learn how you can change directory in DOS.
- MD A (Make directory "A")
- CD A (Change directory to "A")
- CD.. (Back to previous directory)
- CD\ (Back to c:\> directory automatically)
- ECHO
examples:
echo ON | {Restores normal display activity.} | |
echo OFF | {Halts display of DOS prompt and commands.} |
- REM
examples:
@rem {Hides the remark from display.}
- PAUSE
examples:
pause {Displays "Press any key to continue ...".}
- GO TO
examples:
goto LABEL
:LABEL
(you can replace label with any name you want)
- CLS
- IF [Conditional Branching]
Syntax : IF [NOT] EXIST FILENAME command
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
A program to to check the existence of a file (Example)
@echo off
CLS
IF EXIST c:\>abc.dos GOTO PRINT
GOTO end
ECHO FILE EXIST
:ENDThis is just an overview to guide you with BATCH programming, shortly i make an post with some batch programs by which you can also make prank or fake virus in batch programming.
Hope this was informative, kindly post your views or comments on this article . Suggestions are welcomed.
Be a real hacker - PROFESSIONAL, and change the trend of HACKING.
Thanks & Regards:
Sahil Mahajan.
can u add me on this id musaole@yahoo.co.uk pls so that we can chat thanks
ReplyDeletelovely....looking forward to more nice post...cheers...(DEREMMY)
ReplyDelete@ DEREMMY : Thanks, keep visiting
ReplyDeletecan u give some more batch programming codes for hacking
ReplyDelete@ LOHIT : Thanks for your feedback, we shortly make post on it.
ReplyDeleteThis is really usefull for me thank you.
ReplyDelete>5PYB0Y
thank you man, i find your post really usefull
ReplyDelete