Thanks for the code, but it doesnt seem to be working. Are there restrictions on the range? We are actually trying to do it for a 10.128.32/19 range. And it doesnt seem to pick off the IP correctly.

I did a capture of the @IPADDRESS0 value and ensured the formatting was correct for that range, but with the code provided it never seems to get it the way it wants to, so never does anything in the IF statment.