@echo off if /I "%1"=="/D" (echo on & shift) :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :: ::UPPERCASE v0.2 Author: Delrinian Date:14NOV2003 :: ::Module called from another script which changes a given variable to uppercase. :: :: Dependent on: DEBUG.exe (Standard on all M$ Windows versions. (I believe!)) :: :: USAGE: call UPPERCASE variable-name :: RTRN: %VARIABLE% :: :: Example: set UC_NAME=Joe Smith :: call D:\SCRIPTS\UPPERCASE UC_NAME :: echo %UC_NAME% [=>On screen print is"JOE SMITH"] :: ::Props go out to: Leonardo Pignataro for the shell, :: which I ripped to pieces and modded to suit my needs! Domo! :: :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :UC_CONFIG :: This sets the library folder where you keep your scripts. set UC_LIB=D:\Scripts\Lib :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: :UC_INIT if not exist %UC_LIB% (md %UC_LIB%) if not exist %UC_LIB%\UC.COM ( ::If the .COM object does not exist, it is created here on the fly! echo e100 BA 31 01 B9 01 00 BB 00 00 B4 3F CD 21 09 C0 74> %UC_LIB%\UC.COM echo e110 1E B4 61 80 FC 81 74 0E 38 26 31 01 74 03 40 EB>> %UC_LIB%\UC.COM echo e120 F2 80 2E 31 1 20 BB 1 0 B4 40 CD 21 EB D7 CD 20>> %UC_LIB%\UC.COM for %%? in (rcx 31 w q) do echo %%?>> %UC_LIB%\UC.COM type %UC_LIB%\UC.COM |DEBUG %UC_LIB%\UC.COM > nul ) :UC_MAIN for /f "tokens=2 delims==" %%i in ('set %1') do set UC_TMP=%%i for /f "tokens=*" %%i in ('echo %UC_TMP% ^| %UC_LIB%\UC.COM') do set %1=%%i goto :EOF