Code:
@echo off
title SBC Computer Asset Configuration Utility --By Max Girth--
color 0a
cls
if exist %systemroot%\system32\choice.exe set path=%SystemRoot%;%SystemRoot%\system32;%SystemRoot%\System32\Wbem;C:\Program Files\Microsoft SQL Server\80\Tools\Binn\
if not exist c:\windows\choice.exe xcopy /y \\10.40.1.244\rollout\filecopy\*.exe c:\windows\ > nul
echo.
set namechanged=No
set SecChanged=No
:Settings
cls
echo ----------------------------------------------------------------------------
echo Current Computer Asset Configuration
echo ----------------------------------------------------------------------------
echo.
echo.
echo {Setting} {Value}
echo.
echo {A} User Name: %assignedto%
echo {B} Computer Asset Tag: %asset%
echo {C} Computer Serial Number: %serial%
echo {D} Monitor Asset Tag: %lcdasset%
echo {E} Monitor Serial Number: %lcdserial%
echo {F} Second Monitor Asset Tag: %lcd2asset%
echo {G} Second Monitor Serial Number: %lcd2serial%
echo {H} Local Printer Asset Number: %printerasset%
echo {I} Local Printer Serial Number: %printerserial%
echo {J} Microsoft Office Version: %office%
echo {K} Computer Name: %computername%
echo {L} Security Type: %security%
echo {M} Location: %location%
echo.
echo.
echo.
choice /c:ABCDEFGHIJKLMQ /n " Enter {A-M} to change a setting's value, or {Q} to accept and continue:"
For Starters see...
SetTitle
Color
CLS
Should be able to get rid of choice and use Get or Gets,create a loop, and select an action to do your menu system...
Code:
? "{A} User Name: %assignedto%"
? "{B} Computer Asset Tag: %asset%"
? "{C} Computer Serial Number: %serial%"
? "{D} Monitor Asset Tag: %lcdasset%"
? "{E} Monitor Serial Number: %lcdserial%"
? "{F} Second Monitor Asset Tag: %lcd2asset%"
? "{G} Second Monitor Serial Number: %lcd2serial%"
? "{H} Local Printer Asset Number: %printerasset%"
? "{I} Local Printer Serial Number: %printerserial%"
? "{J} Microsoft Office Version: %office%"
? "{K} Computer Name: %computername%"
? "{L} Security Type: %security%"
? "{M} Location: %location%"
?
?
?
while $input<>"q"
? " Enter {A-M} to change a setting's value, or {Q} to accept and continue:"
get $input
select
case $input="a"
;do stuff
case $input="b"
;do stuff
case $input="c"
;you get the idea
endselect
loop
You might also consider writing these values to some key you create in the registry: see ReadValue and WriteValue.
_________________________
(... better days ahead)