Plotting events on Bing Maps
In Chapter 3, Using Maps in your Windows Phone App, we saw how to use Bing Maps and pushpins within our apps. Now, let us use that knowledge to incorporate maps within our "Hello Events" franchise:
1. Create a new Silverlight for Windows Phone project and Name it
HelloEvents-Maps
.2. Copy the code and UI from our previous
HelloEvents-Categories
example. We will make some changes in theEventPage.xaml
andEventPage.xaml.cs
files to show maps and events plotted on the maps.3. Add a button and a map control to your
EventPage.xaml
file just below theListBox
control. YourContentPanel
grid should now contain the following lines of code:<Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,30"> <ProgressBar Name="loadingBar" Margin="0,251,0,263" IsIndeterminate="true"></ProgressBar> <ListBox Height="555" HorizontalAlignment="Left" Margin="2,6,0,0" Name="myEventsList"VerticalAlignment="Top" Width="448"></ListBox> <Button Content...