- Joined
- Dec 7, 2008
- Messages
- 74
- Trophies
- 0
- Location
- In font of my computer
- Website
- Visit site
- XP
- -9
- Country
-
1.How to make a Batch file (.bat file).
a.First open Notepad or use option b.
b.1.Go to Start
b.2.Start Run...
b.3.Give in "notepad" without the ".
2.Then use the commands that you can find in this Blog.
3.Use file "Save As".
4.You have to change "Save as type "Text Documents (*.txt)" to "All Files".
5.Now give the "File name" in for example batch.bat and always say .bat on the end!!
6.Now save and you have your Batch file (.bat)
Commands with discribtion:
@echo off = Put this on the top of a .bat and it won't show all the pads it use example: C:\Program Files\Internet Explorer
echo = Write "echo Hello World" and on the screen apeers "Hello World"
echo. = Make a clear line on the screen.
DATE = Show or set date.
DATE /T = Only show date
TIME /T = Only time
TIME = Show or set time
pause = Pause it sayes " Press any key to continue..."
cls = Clear screen
exit = Exit the .bat file
del. =WARNING do not use this command it will clear your COMPLETE Hard drive!!
del "C:\Program Files\Internet Explorer" = it will delete the map/file
call = Start another .bat in your .bat file
start calc = The .bat will start calculator i use this a an example you can use notepad or other progr.
goto = goto says goto ... example goto 1 then he goes to :1
shutdown -s -t 7 = The computer will shutdown himself in 7 sec without saving anything. 7 stands for 7 sec.
dir = Displays files in a directory.
mkdir = Makes a directory
dir >> a.txt outputs the result of the command to a text file.
rename = Renames a file, remember to use " when spaces are in the name/location.
help (command name) =Gives you info about command (works fine in cmd.exe)
:Colors
Color [attr]
attr Specifies color tribute of console output
Color attributea are specified by TWO hex digits -- the first
correspondds to the background; the second the foreground. Each digit
can be any of the following values:
0 =Black 8 =Gray
1 =Blue 9 =Light Blue
2 =Green A =Light Green
3 =Aqua B =Light Aqua
4 =Red C =Light Red
5 =Purple D =Light Purple
6 =Yellow E =Light Yellow
7 =White F =Bright White
shutdown commands:
first option
-l Log off (cannot be used with -m option)
-s Shutdown the computer
-r Shutdown and restart the computer
-a Abort a system shutdown
-m \\computername Remote computer to
example: SHUTDOWN -s
ING = Test a network connection - if successful, ping returns the ip address.
Code: PING [options] destination_host
-w timeout Timeout in milliseconds to wait for each reply.
-i TTL Time To Live.
-v TOS Type Of Service.
-a Resolve addresses to hostnames.
-n count Number of echo requests to send.
-t Ping the destination host until interrupted.
-l size Send buffer size.
-f Set Don't Fragment flag in packet.
-r count Record route for count hops.
-s count Timestamp for count hops.
-j host_list Loose source route along host_list.
-k host_list Strict source route along host_list.
destination_host The name of the remote host
How to make a menu in xp:
set INPUT=
set /P INPUT=Say yes or no!:
if "%input%" =="yes" goto yes
if "%input%" =="no" goto no
:yes
echo You said yes.
pause
:no
echo You said no.
pause
In The menu you also can use the :
)ELSE(
goto else
Command it says if you give something in like "wtf" it goto :else
If some of you have some command I don't know or wants to correct my add a post/pm me and i will add it to the list!

a.First open Notepad or use option b.
b.1.Go to Start
b.2.Start Run...
b.3.Give in "notepad" without the ".
2.Then use the commands that you can find in this Blog.
3.Use file "Save As".
4.You have to change "Save as type "Text Documents (*.txt)" to "All Files".
5.Now give the "File name" in for example batch.bat and always say .bat on the end!!
6.Now save and you have your Batch file (.bat)
Commands with discribtion:
@echo off = Put this on the top of a .bat and it won't show all the pads it use example: C:\Program Files\Internet Explorer
echo = Write "echo Hello World" and on the screen apeers "Hello World"
echo. = Make a clear line on the screen.
DATE = Show or set date.
DATE /T = Only show date
TIME /T = Only time
TIME = Show or set time
pause = Pause it sayes " Press any key to continue..."
cls = Clear screen
exit = Exit the .bat file
del. =WARNING do not use this command it will clear your COMPLETE Hard drive!!
del "C:\Program Files\Internet Explorer" = it will delete the map/file
call = Start another .bat in your .bat file
start calc = The .bat will start calculator i use this a an example you can use notepad or other progr.
goto = goto says goto ... example goto 1 then he goes to :1
shutdown -s -t 7 = The computer will shutdown himself in 7 sec without saving anything. 7 stands for 7 sec.
dir = Displays files in a directory.
mkdir = Makes a directory
dir >> a.txt outputs the result of the command to a text file.
rename = Renames a file, remember to use " when spaces are in the name/location.
help (command name) =Gives you info about command (works fine in cmd.exe)
:Colors
Color [attr]
attr Specifies color tribute of console output
Color attributea are specified by TWO hex digits -- the first
correspondds to the background; the second the foreground. Each digit
can be any of the following values:
0 =Black 8 =Gray
1 =Blue 9 =Light Blue
2 =Green A =Light Green
3 =Aqua B =Light Aqua
4 =Red C =Light Red
5 =Purple D =Light Purple
6 =Yellow E =Light Yellow
7 =White F =Bright White
shutdown commands:
first option
-l Log off (cannot be used with -m option)
-s Shutdown the computer
-r Shutdown and restart the computer
-a Abort a system shutdown
-m \\computername Remote computer to
example: SHUTDOWN -s
Code: PING [options] destination_host
-w timeout Timeout in milliseconds to wait for each reply.
-i TTL Time To Live.
-v TOS Type Of Service.
-a Resolve addresses to hostnames.
-n count Number of echo requests to send.
-t Ping the destination host until interrupted.
-l size Send buffer size.
-f Set Don't Fragment flag in packet.
-r count Record route for count hops.
-s count Timestamp for count hops.
-j host_list Loose source route along host_list.
-k host_list Strict source route along host_list.
destination_host The name of the remote host
How to make a menu in xp:
set INPUT=
set /P INPUT=Say yes or no!:
if "%input%" =="yes" goto yes
if "%input%" =="no" goto no
:yes
echo You said yes.
pause
:no
echo You said no.
pause
In The menu you also can use the :
)ELSE(
goto else
Command it says if you give something in like "wtf" it goto :else
If some of you have some command I don't know or wants to correct my add a post/pm me and i will add it to the list!