I tried something like that before, but ? had a problem displaying %comspec%. I didnt feel like using ExpandEnvironmentVars, so I didnt get into it (remember, when you drop to shell you are using a different environment).

What I did test was
code:
 
$LMHostsPath = "@LanRoot\drivers\etc\"
$LMH = "$LMHostsPath" + "lmhosts."
$num = 10
? "/c ren $LMH$num $LMH"

which displayed correctly. I suppose if I had a real woody for it I could have used the shell and had it echo... which I will try now that I thought of it.

Also, does anyone know what went wrong with using Kixtart's copy command? This is what exited with error code 2-

code:
 
:COPYLMH
$LMH = "$LMHostsPath" + "lmhosts."
Select
Case "$Loc" = "DePaul" copy "lmhosts.10" "$LMH" /h
Case "$Loc" = "Lexington" copy "lmhosts.10" "$LMH" /h
Case 1 copy "lmhosts.167" "$LMH" /h
EndSelect
Return

_________________________
Be kind; each person is fighting his own private war.