Batch ToolKit V 1.00.A

Download Batch ToolKit V 1.00.A 56.5KB.

Becho Message Tnd - Time 'n Date Select Getline


Becho V 1.00.A

Becho is a replacement for the `echo` command of DOS. Becho is a very powerful program and with proper use, one can work wonders with it.

Command Line Options
-FxxxxxxxFont Color. Replace <xxxxxxx> with color name. It can be any colour in the colour chart.
-BxxxxxxxBackground Colour. Replace <xxxxxxx> with color name. It can be any background colour in the colour chart.
-blinkEnables Blinking mode.
-X Enables eXtended mode. In this mode you can give diffrent colours for the same line. An example is given below.
becho -x -f4 http:// -b7 -f0 \bwww. -b2 -f15 "\bboocities.com/" -b3 -f13 \bbinnyva
Result :
C:\DOS>becho -x -f4 http:// -b7 -f0 \bwww. -b2 -f15 "\bboocities.com/" -b0 -f13 \bbinnyva
http:// www. geocites.com/ binnyva
C:\DOS>_
-noblink shuts off the blinking mode aftter it is enabled.
Note : The whole command must be given in one line.


Inline Formatting

You can use the codes given below in the strings that you give to get untypeable characters like New Line, Audible Bell etc.

CodeDoes this
\aSounds a bell
\bBackspace
\nNew line
\tTab character
\\Prints a slash(\)



tnd - Time 'n Date   V 2.00.A

Tnd Page

This command displays the time and date in the format specified at command line.

Command Line Options
-tShows Time in "Hours:Min AM/PM" Format
-dShows Date in "D-M-Y" Format
-dmShows Date in "D-M" Format
-mdShows Date in "M-D" Format
-lDisplay day in Long Format - 1st January 2000.
-0Add 0 to the number. 1-9-2004 becomes 01-09-2004
-?Displays Help screen
-xAllows eXtended formatting of date and time.
  After the '-x' leave a space and type the following
 
/dFor Day /DFor zeros in day(1 becomes 01)
/mFor Month /MFor month with zeros
/wFor small name of Weekday (Mon,Tue, etc.) /WFor name of Weekday (Monday,Tuesday, etc.)
/nFor small Name of the month (Jan, Feb, etc.) /NFor Name of the month (January, February, etc.)
/yFor Year/YFor 4 digit year(2004)
/hFor Hour/HFor hours with zeros
/2For hours in 24 hour clock
/eFor minutE/EFor minutEs with zeros
/aFor AM/PM
/-For putting the character '-'
/_For putting a space ' '
/'For putting a quotes character (")

Note : The inline formatting option use '/' and not '\'.

Example
I am assuming that you use windows. If this should be done in dos some changes should be made.
1) To make a folder with today's date. Make a batch file with the below content and run it.
@echo off
becho mkdir > c:\windows\temp\tmp$~.bat
becho " \"">> c:\windows\temp\tmp$~.bat
tnd -x "/M - /D\'" >> c:\windows\temp\tmp$~.bat
echo. >> c:\windows\temp\tmp$~.bat
call c:\windows\temp\tmp$~.bat

2) Get today's date into a file. Run this command and replace "filename.ext" with the name of the file.
tnd -l >> filename.ext
3) Get the time into a file. Run this command and replace "filename.ext" with the name of the file.
tnd -t >> filename.ext



Message 1.00.A

Usage : Message [OPTIONS] "<Message Text>"

Shows a message box with the text specified as the argument. This message box can be in the from of an alert - just the OK button or as a conformation box - two buttons will be shown - OK and Cancel(can be changed). Any one button can be chosen using the arrow keys and enter. If OK is selected, the errorlevel will be set to 1 and if Cancel is selected, the error level will be 0. The text colour and background colour of all elements can be set from the command line. All the command line options are described below.

Example: message -bg blue -t BLACK -hs "Hello World"

Command Line Options
--hide_shadow OR -hs- Disables the drop shadow effect.
--yesno OR -yn- The Button text will be 'Yes' and 'No'.
--okcancel OR -oc- The Button text will be 'OK' and 'Cancel'.
--delimiter <#> OR -d <#>- Sets the delimiter at the ends of the button.
<#> can be any of the following values.
 
CodeButton Text
0Text (No Delimiters)
1< Text >
2- Text -
3[ Text ]
4.: Text :.
-? OR --helpShows help screen (this screen)
-? breakShows help page by page.

Example : message -yn --delimiter 4 "Hello World"

Colour Options
The all the colours can be set from the command line. The format is given below.
Note : MB - Message Box
Command LineFunction
--border_color <colour> OR -bc <colour>The colour of the border of the MB.
--background <colour> OR -bg <colour>The background colour MB.
--text_color <colour> OR -tc <colour>The text colour in MB.
--button_text_color <colour> OR -btc <colour>The text colour of the selected button.
--button_background <colour> OR -bbg <colour>The background colour of the selected button.
--disabled_text_color <colour> OR -dtc <colour>The text colour of the button that is NOT selected.
--disabled_background <colour> OR -dbg <colour>The background colour of the button that is NOT selected.
--shadow_color <colour> OR -sc <colour>The colour of the Shadow.

<colour> can be any color specified in the Colour Chart. You can use the code instead of the colour name. Please be careful to give only the first 8 colors in the chart as the background color.




Select 1.00.A

Usage : Select [OPTIONS] <Menu Item> <Menu Item> <Menu Item> ...

Select will show a interactive arrow-keys driven menu from which the user can make a selection. The number of the selection will be set as the errorlevel. The is useful in batch scripts. The text colour and background colour can be set from the command line.
Note : If a item is more than one word enclose it in quotes. Like "Menu Item".

Command Line Options
--hide_info OR -hiHides the "Currently Selected" text.
--show_numbers OR -snShows numbers for each element in the menu.
--no_fill OR -nfThis will cause the background to be the same width as the text.
-? OR --helpShow help screen (this screen)
-? breakShows help page by page.


Colour Options
The text colour and background colour can be set from the command line. The format is given below.
Command LineFunction
--back <colour> OR -b <colour>Sets the default background colour.
--text <colour> OR -t <colour>Sets the default text colour.
--select_back <colour> OR -s <colour>Sets the background colour for selected items.
--select_text <colour> OR -t <colour>Sets the colour of the selected item.

<colour> can be any color specified in the Colour chart. You can use the code instead of the colour name. Please be careful to give only the first 8 colors in the chart as the background colour.

Example:
select "Item 1" "Item 2" "Item 3" -b LIGHTGRAY -t BLACK -sb LIGHTGREEN -st RED



Getline 1.00.A

Usage : Getline <FileName> [OPTIONS] <StartLineNumber> [ - ] [<EndLineNumber>]

This command will show the contents of a file from <StartLineNumber> to <EndLineNumber> which can be specified at command line. If <EndLineNumber> is omitted, only line number <StartLineNumber> is is shown. If <EndLineNumber> is end or 0 or greater than the last line number, everything from <StartLineNumber> to end of file is shown.

Example : getline autoexec.bat 2 - end

Command Line Options
-vVerbose Mode
-noerrorWill not display any error.
-? OR -hDisplay the help screen.



Colour Chart

Colour NameCode BackgroundExample
BLACK0YesExample
BLUE1YesExample
GREEN2YesExample
CYAN3YesExample
RED4YesExample
MAGENTA5YesExample
BROWN6YesExample
LIGHTGRAY7YesExample
DARKGRAY8NoExample
LIGHTBLUE9NoExample
LIGHTGREEN10NoExample
LIGHTCYAN11NoExample
LIGHTRED12NoExample
LIGHTMAGENTA13NoExample
YELLOW14NoExample
WHITE15NoExample