windows phone page XAML Preview not showing in Blend and Visual studio

271 views Asked by At

I have written code in mainpage.xaml in universal app project and windows phone 8.1 section. The preview in visual studio and blend is showing as empty. Pictures are attached. NO TEXT of text block set from back c# code. all code is set here. Windows phone ouput is also attached. Following is the code

<Page 
x:Class="PakistanNewspapers.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:PakistanNewspapers"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">

<Hub>
    <Hub.HeaderTemplate>
        <DataTemplate>
            <TextBlock x:Name="lblHeader" Text="Pakistani Newspapers"></TextBlock>
        </DataTemplate>
    </Hub.HeaderTemplate>
<HubSection Header="Urdu Newspapers" >
    <DataTemplate>
        <Grid>
            <Grid.RowDefinitions>
                <RowDefinition Height="*"></RowDefinition>
                <RowDefinition Height="*"></RowDefinition>
            </Grid.RowDefinitions>
            <StackPanel Orientation="Vertical">
                <GridView>
                    <GridView.ItemTemplate>
                        <DataTemplate>

                            <StackPanel Margin="0,0,0,0" Orientation="Horizontal">

                                <Image x:Name="txtNewspaperImage" Height="60" Width="60" VerticalAlignment="Center" Margin="0,0,10,0"/>
                                <StackPanel Orientation="Vertical">
                                    <TextBlock x:Name="txtNewspaperHeader" TextWrapping="Wrap" Foreground="{StaticResource ApplicationForegroundThemeBrush}" FontSize="14.667" FontWeight="Light" Width="200" VerticalAlignment="Center" HorizontalAlignment="Left" FontFamily="Segoe UI"/>
                                    <TextBlock x:Name="txtNewsHeader" TextWrapping="Wrap" Foreground="{StaticResource ApplicationForegroundThemeBrush}" FontSize="14.667" FontWeight="Light" Width="200" MaxHeight="20" VerticalAlignment="Center" HorizontalAlignment="Left"/>
                                </StackPanel>

                            </StackPanel>
                        </DataTemplate>

                    </GridView.ItemTemplate>
                </GridView>

            </StackPanel>
        </Grid>
    </DataTemplate>

</HubSection>

<HubSection Header="English Newspapers"/>

<HubSection Header="About"/>
</Hub>

While the preview in visual studio and blend is showing as : Visual Studio Blend Windows Phone

0

There are 0 answers