<UserControl x:Class="Route.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:m="clr-namespace:Microsoft.Maps.MapControl;assembly=Microsoft.Maps.MapControl"
    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="400">

    <UserControl.Resources>
        <m:ApplicationIdCredentialsProvider x:Key="BingStorageCred" ApplicationId="your key" />
    </UserControl.Resources>

    <Grid x:Name="LayoutRoot" Background="White">
        <Grid.RowDefinitions>
            <RowDefinition Height="*" />
            <RowDefinition Height="auto"/>
        </Grid.RowDefinitions>
        <m:Map Name="myMap" CredentialsProvider="{StaticResource BingStorageCred}" Grid.Row="0" Culture="De-de" ></m:Map>
        <Grid Grid.Row="1">
            <Grid.RowDefinitions>
                <RowDefinition></RowDefinition>
                <RowDefinition></RowDefinition>
                <RowDefinition></RowDefinition>
            </Grid.RowDefinitions>
            <TextBox Name="txtStart" Grid.Row="0" Text="Enter the start address or location here." Background="LightGray"    Width="300" HorizontalAlignment="Left"></TextBox>
            <TextBox Name="txtEnd" Grid.Row="1" Text="Enter the end address or location here." Background="LightGray"  Width="300" HorizontalAlignment="Left"></TextBox>
            <Button Name="btnCalculateRoute" Grid.Row="2" Content="Calculate Route" Background="Black"  Width="100" HorizontalAlignment="Left" Click="Button_Click"></Button>
        </Grid>
    </Grid>
</UserControl>
