M
MS Newsgroups
Hi,
does anyone have a function, or some insight in how i would go about to be
able to calculate the first and last address in a IP subnet based on a
network address and bits
Example 192.168.1.0 / 24
Should return
Firstaddresss 192.168.1.1
Lastaddress 192.168.1.254
OR -
192.168.1.32 / 27
FirstAddress 192.168.1.33
LastAddress 192.168.1.63
I know that there are IP subnet calculators out there, but i have not seen
any samples with source code.
All help would be much appreciated
Many thanks
Nick
does anyone have a function, or some insight in how i would go about to be
able to calculate the first and last address in a IP subnet based on a
network address and bits
Example 192.168.1.0 / 24
Should return
Firstaddresss 192.168.1.1
Lastaddress 192.168.1.254
OR -
192.168.1.32 / 27
FirstAddress 192.168.1.33
LastAddress 192.168.1.63
I know that there are IP subnet calculators out there, but i have not seen
any samples with source code.
All help would be much appreciated
Many thanks
Nick