The Red Warriors

SEKeLUMIT TenTang AKU

My photo
Sweetest Place, MeloDy BeacH, Malaysia
TAK BOLEh M3NANG SeLAGI TAK BLAJAR m3NGALaH!!11!!1!!1!!!!!!!!!!

Tuesday, March 23, 2010

Simple Batch Tutorial

Apa yang diperlukan?
-notepad
-keyboard
-keinginan

Lets go.. making the batch
the first line

@echo off  

Kenapa @echo off?Apa akan jadi kalau @echo on? ini kerana @echo off tidak akan menunjukkan directory sesuatu batch.(You can experiment a little if you want).

untuk memaparkan ucapan "HELLO WORLD"

@echo off
echo HELLO WORLD

yeah now go to file save and name it test.bat
run it.
hahaha ape akan terjadi?
black box open and close fastly.

to fix this, we used the pause command, goto command (looping) and exit command
(eksperimen dengan semua command)
cth:-

@echo off 
echo HELLO WORLD
pause
.........................................

@echo off 
echo HELLO WORLD
exit
..........................................

@echo off
:pause 
echo HELLO WORLD
goto pause
.........................................

Save and run it. You should able to read your text now.

msg * -bring up the pop up(msg box)


@echo off
echo HELLO WORLD
msg * my name is nazra
pause

yeah cayouk cayouk...

copy command (copy itself)
contoh:-

@echo off
copy nazra C:\WINDOWS


copy-arahan untuk copy
nazra-nama file yang hendak dicopy
C:\WINDOWS-directory kemana @ is the place you want to copy to.

Exploit Command (command yang merosakkan)

del -delete files
del file name
del (.exe*)
(.exe*) akan delete semua exe files dalam computer dan * bermaksud SEMUA files yang bernama exe

format -deletes evrything
format C:
akan deletes segala benda dalam C drive.

start -open something (to scare someone)
start notepad
(to open notepad type)
start mspaint
(to open microsoft paint type)
untuk lebih advance lagi buat looping untuk open command (kena shut down haha)

@echo off
:start
start notepad
start mspaint
goto start

ini akan menyebabkan notepad dan mspaint terbuka dan terbuka.(eksperimen tanpa function loop)
to open the command window you have to use var like %% (not going to explain var.)

@echo off
:start
start %
goto start

this will open the black box(command window) over and over and
will crash the window if they dont close its.
as the conslusion

@echo off
:start
title nazra edition
start notepad
start mspaint
start damn.bat
msg * msg from the n4zr4
goto start
[ ... ]