Sign in to follow this  
Followers 0
MattX

Quick IP Scope Question

7 posts in this topic

Is it possible to code a conditional statement using an IP scope ? Example:

IF IP Address = 10.165.5.XX then

Do something

Can @IPaddress1 be used or will it have to be done differently ? And if differently I'm after a suggestion !!

Thanks.

Share this post


Link to post
Share on other sites



You mean where XX could be any number but the rest must remain the same?

Yes.

Share this post


Link to post
Share on other sites

Thanks - I'll give that a go later - will let you know when I get stuck..... :)

Share this post


Link to post
Share on other sites

Keep in mind, that the dot has a special meaning in regular expressions (any character), so you should use .

StringRegExp("12.13.14.45", "^12.13.14.d{1,3}$", 1)

Meaning:

^ - Match beginning of string

12 - Match characters 1 and 2

. - Match a dot

13 - Match 13

. - dot

14 - 14

. - dot

d{1,3} - match specific amount of digits: at least one, at most three

$ - Match end of string


*GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0