string url = "http://www.webxml.com.cn/WebServices/WeatherWebService.asmx";
string[] args = new string[1];
args[0] = "上海";
object ob = WSHelper.InvokeWebService(url, "getWeatherbyCityName", args);
string[] str = (string[])ob;
StringBuilder sb = new StringBuilder();
if (ob == null)
{
sb.AppendLine("暂无信息");
}
else
{
foreach (var item in str)
{
sb.AppendLine(item);
}
}
return sb.ToString();