2014-12-04 75 views
1

调用php webservice这是我的代码,我不想在Windows Phone应用程序中调用webservice。无法通过参数

client.DownloadStringAsync(new Uri("http://example.com/get_places_nearby.php?longitude="+itravelObj.getGPSLongitude()+"&latitude="+itravelObj.getGPSLatitude(), UriKind.Relative)); 

帮助,请..

回答

0

想你需要更改URI到UriKind.RelativeUriKind.Absolute

client.DownloadStringAsync(new Uri("http://example.com/get_places_nearby.php? 
    longitude="+itravelObj.getGPSLongitude()+"&latitude="+itravelObj.getGPSLatitude(), 
    UriKind.Relative)); 

因为你开始http://www.website.com