Can I get weather for my location?



Can I get weather for my location?..

Answer / Dileep Yadav

Yes, you can retrieve the current weather for your location using the Bing Maps SDK. The SDK provides a LocationService class that helps to determine the user's location and get related data like weather. Here's a simple example:

```csharp
var map = new MapControl();
var locationService = new LocationService(map);
locationService.GetLocationAsync().ContinueWith((task) =>
{
if (task.IsFaulted || task.IsCanceled)
{
// handle errors
}
else
{
var geoCoordinate = task.Result;
// use the geoCoordinate to make a request for weather data
}
});n

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Windows Phone OS Interview Questions

Explain how to get the geolocation data on a picture?

1 Answers  


Explain where is xmldocument class?

1 Answers  


Explain how to dismiss the sip programmatically?

1 Answers  


Suppose have a very simple application that uses the applicationbar. The app bar shows one menu item when in portrait. However as the second image shows theapp bar displays now items in landscape mode. Is that by design or a bug?

1 Answers  


Can I open sockets in windows phone?

1 Answers  


What is windows phone media support?

1 Answers  


Explain Windows Phone Hardware?

1 Answers  


The MarketPlace Launchers overloads for Show has parameters, what are these?

1 Answers  


Is it possible to run two instances of emulator on the same machine. I am doing some networking app and need two emulators to test it?

1 Answers  


Tell me can I get weather for my location?

1 Answers  


How to edit locations for local?

1 Answers  


Tell me can I write multi-player games using wi-fi or blue tooth in the device.?

1 Answers  


Categories