Nancy Street

nvarcmd

Click to see the Site Map
HomeInfoMusicGalleryPetsGeoHobbiesGeo
Site MapWhat's NewRecent ChangesContactsServer StatisticsSite Information Home « Computers « nvarcmd

varcmd is a .NET console command line utility written in C# that issues commands with variables substituted at runtime. This program can be very useful in batch files where files and directories can be created with dynamic dates and times or values prompted from the user.

Here is the help display from nvarcmd when no parameters are entered:

Description
nvarcmd is a console command that issues an operating system command from a
string that can contain variables that are substituted at runtime. The
variables can be parts of the date and time, environment variables or values
taken from dialogs. The command was intended for use in batch files.
Examples
nvarcmd "mkdir c:\backups\$Y$m$d"
nvarcmd "dir ""%(TEMP)\*.tmp""
nvarcmd "copy ""$(File to copy)"" ""%(TEMP)"""
Variables
$y ............ YY (year)
$Y ............ CCYY (century and year)
$m ............ MM (month)
$M ............ MMM (Month name prefix)
$d ............ DD (day)
$D ............ DDD (day name prefix)
$h ............ HH (hour)
$n ............ NN (minute)
$s ............ SS (second)
$(P:prompt) ... Dialog prompt for value
$(F:title) .... File picker dialog
$(D:title) .... Folder browser dialog
%(env) ........ Environment variable

Download

nvarcmd_proj.zip - (34KB) ZIP of the Visual Studio 2005 project.
nvarcmd_exe.zip - (0KB) Zip of the executable.

Back to: Computers & Software Main Page


Contact Information | PGP Keys | Site Map | What's New | Visitor Book
Last Updated: 06-Aug-2007 21:12
Copyright © 1999-2007 Orthogonal Programming