M
Matt G
Hi,
When I do this in a batch file on a Windows 2003 server...
SET IPADDRESS=10.1.10.20
FOR /F "TOKENS=1,2,3,4 DELIMS=." %%A IN (%IPADDRESS) DO @(
SET octet1=%%A
SET octet2=%%B
SET octet3=%%C
SET octet4=%%D
)
SET reversezone=%octet3%.%octet2%.%octet1%
SET subnet=%octet1%.%octet2%.%octet3%.0/24
echo ipaddress=%IPADDRESS%
echo reversezone=%reversezone%
echo subnet=%subnet%
I get this:
ipaddress=10.1.10.20
reversezone="10"."1"."10"
subnet="10"."1"."10".0/24
I don't want the quotes around each octet in reversezone and subnet. Anyone
know how to remove them?
Thanks in advance.
When I do this in a batch file on a Windows 2003 server...
SET IPADDRESS=10.1.10.20
FOR /F "TOKENS=1,2,3,4 DELIMS=." %%A IN (%IPADDRESS) DO @(
SET octet1=%%A
SET octet2=%%B
SET octet3=%%C
SET octet4=%%D
)
SET reversezone=%octet3%.%octet2%.%octet1%
SET subnet=%octet1%.%octet2%.%octet3%.0/24
echo ipaddress=%IPADDRESS%
echo reversezone=%reversezone%
echo subnet=%subnet%
I get this:
ipaddress=10.1.10.20
reversezone="10"."1"."10"
subnet="10"."1"."10".0/24
I don't want the quotes around each octet in reversezone and subnet. Anyone
know how to remove them?
Thanks in advance.