REM ***** BASIC ***** Function Long2IP(addr as Double) as String a = fix(addr / 16777216) b = fix(( addr - 16777216 * a) / 65536) c = fix(( addr - 16777216 * a - 65536 * b ) / 256) d = fix( addr - 16777216 * a - 65536 * b - 256 * c ) Long2IP = Format(a, "000") + "." + Format(b, "000") + "." + Format(c, "000") + "." + Format(d, "000") End Function Function Main(addr as Variant) as String DIM res as String IF IsMissing(addr) THEN res = "Missing Argument" ELSEIF IsArray(addr) THEN res = "Array" ELSEIF IsNumeric(addr) THEN res = Long2IP(addr) ELSE res = "String" END IF Main = res End Function