PC Review Forums Newsgroups Microsoft DotNet Microsoft VB .NET IP Subnet Test

Reply

IP Subnet Test

 
Thread Tools Rate Thread
Old 21-05-2006, 10:23 PM   #1
Niclas
Guest
 
Posts: n/a
Default IP Subnet Test


Hi,

Does anyone have some code that would allow me to test if a specific IP
address is within a specific IP range or a distinct subnet or similar ?

Any help appreciated.

Thanks

Niclas


  Reply With Quote
Old 22-05-2006, 05:49 PM   #2
aaron.kempf@gmail.com
Guest
 
Posts: n/a
Default Re: IP Subnet Test

you can use the parsename function in sql server to do this.

parsename(@myIP, 3) = '192' AND parsename(@myIP, 2) = '168'

etc

  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off