title: Windows Phone 7 Consuming Webservice WSDL
body: <p>Ok I have written some basic generic webservices before but I have never tried to consume a 3rd party one. 
  The one I am trying to consume is 
  <a href="http://opendap.co-ops.nos.noaa.gov/axis/webservices/predictions/wsdl/Predictions.wsdl" rel="nofollow">http://opendap.co-ops.nos.noaa.gov/axis/webservices/predictions/wsdl/Predictions.wsdl</a></p>
  
  <p>I am not getting any results back from this what so ever and cannot figure out why. 
  More odd is it is not even reaching PredictionsClient_getPredictionsAndMetadataCompleted when I put a break point in the code it doesn't even reach it. 
  Any suggestions would be greatly appreciated</p>
  
  <pre><code>    public void Bouy(double meters)   
      {   
          PredictionService.Parameters PredictionParams = new PredictionService.Parameters();   
          PredictionService.PredictionsPortTypeClient PredictionsClient = new PredictionService.PredictionsPortTypeClient();   
  
          GeoCoordinateWatcher gc = new GeoCoordinateWatcher(GeoPositionAccuracy.Default);   
          //gc.Position.Location.Latitude, gc.Position.Location.Longitude   
          GeoCoordinate myLocation = new GeoCoordinate(27.931631,-82.802582);   
  
  
          foreach (var bl in BouyLocation.GetAll())   
          {    
              GeoCoordinate otherLocation = new GeoCoordinate(bl.Lat, bl.Lon);   
  
                  PredictionParams.beginDate = DateTime.Now.ToString("yyyyMMdd");   
                  PredictionParams.endDate = DateTime.Now.AddDays(1.0).ToString("yyyyMMdd");   
                  PredictionParams.stationId = bl.LocationID;   
                  PredictionParams.timeZone = 0;   
                  PredictionParams.unit = 1;   
                  PredictionParams.dataInterval = 6;   
                  PredictionsClient.getPredictionsAndMetadataCompleted += new EventHandler&lt;PredictionService.getPredictionsAndMetadataCompletedEventArgs&gt;(PredictionsClient_getPredictionsAndMetadataCompleted);   
  
                  PredictionsClient.getPredictionsAndMetadataAsync(PredictionParams);   
  
  
              double mymeters = myLocation.GetDistanceTo(otherLocation);   
              if (mymeters &lt; meters)   
              {   
                  TextBlock DynTextBlock = new TextBlock   
                  {   
                      Name = "Appearance" + bl.LocationID,   
                      Text = bl.LocationName + PredictionResult,   
                      TextWrapping = System.Windows.TextWrapping.Wrap,   
                      Margin = new Thickness(12, -6, 12, 0),   
                      Style = (Style)Resources["PhoneTextSubtleStyle"]   
  
                  };   
  
                  DynamicAppearance.Children.Add(DynTextBlock);   
                  this.nearByLocations.Add(new BouyLocationModel() { LocationName = bl.LocationName, LocationID = bl.LocationID, Lat = bl.Lat, Lon = bl.Lon });   
              }   
          }   
          var test = nearByLocations;   
      }   
  
      void PredictionsClient_getPredictionsAndMetadataCompleted(object sender, PredictionService.getPredictionsAndMetadataCompletedEventArgs e)   
      {   
          string err = e.Error.ToString();   
  
          PredictionResult = e.Result.ToString();   
      }  
  </code></pre>