根据IP地址返回IP的详细信息(Web Service)
2012-08-30 15:18
363 查看
接口:http://www.sz3w.net/Service/GetIPArea.asmx?op=GetSignIPArea
上述是我做的ip转ip详细的代码,部分看不懂关系,看关键代码就可以
protected void Button1_Click(object sender, EventArgs e) { int pagesize = Convert.ToInt32(PageSize.Text.ToString()); int pageindex = Convert.ToInt32(PageIndex.Text.ToString()); List<Vote> votes=DBHELP.QueryList(pagesize, pageindex); if (votes != null) { ServiceIP.GetIPArea getip = new GetIPArea(); foreach (Vote v in votes) { string msg = getip.GetSignIPArea(v.IP); if (msg.Substring(4, 2) == "-1") { v.IPaddress = "无效IP"; } else { string[] strs = msg.Split('|'); v.IPaddress = strs[0].Substring(8) + strs[2].Substring(5); } DBHELP.DataUpdate(v); } Label1.Text = "执行完成!"; } else { Label1.Text = "没有数据了!"; } }
上述是我做的ip转ip详细的代码,部分看不懂关系,看关键代码就可以
相关文章推荐
- 根据IP地址获取IP的详细信息
- 根据IP地址获取IP的详细信息
- 根据IP地址获取详细的地域信息
- java根据ip地址获取详细地域信息
- Java-----根据IP地址获取详细的地域信息
- java获取远端ip并根据ip得到详细地址信息
- java根据ip地址获取详细地域信息
- java根据ip地址从第三方接口获取详细的地理位置地域信息
- java根据ip地址获取详细地域信息
- java根据ip地址获取详细地域信息的方法
- Java根据IP地址获取详细地域信息
- 根据IP地址获取详细的地域信息
- java根据ip地址获取详细地域信息
- java根据ip地址获取详细地域信息的方法
- JAVA根据IP地址获取详细的地域信息
- JAVA根据IP地址获取详细的地域信息
- java根据ip地址获取详细地域信息
- 根据输入的IP或子网返回网络、掩码、广播、反向解析、子网数、IP类型等信息
- java根据ip地址获取详细地域信息
- JAVA根据IP地址获取详细的地域信息