View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
ShaneDevenshire ShaneDevenshire is offline
external usenet poster
 
Posts: 2,344
Default IP Address Validation?

Hi,

1. An alternate but not quite as complex a solution would be to choose
Data, Validation, Whole Numbers, Between 100000000000 and 999999999999.
And then to apply a custom format to the cell of 000"."000"."000"."000 by
going to Format, Cell, Number tab, Custom. Or if a valid address could be
000.000.000.001 then set the lower limit to 1.

2. If you want a stronger data validation then:
Use the custom with a formula of the following type
=AND(LEN(F1)=12,--LEFT(F1,3)<256,--MID(F1,4,3)<256,--MID(F1,7,3)<256,--MID(F1,10,3)<256)
Where you are applying it to the cell F1 to start. Now have the user enter
the IP address without decimal points and use the format I showed in #1.


If this is helpful, click the Yes button.
--
Thanks,
Shane Devenshire


"GD" wrote:

How do you setup a column to accept an IP address format only, i.e.,
999.999.999.999?