问题描述
我已经解析了以下网址
http://www.teluguone.com/news/tonefeeds/politics/politics-39.rss
http://www.teluguone.com/news/tonefeeds/politics/politics-39.rss
我没有得到任何错误甚至警告。但是o / p没有显示黑屏。
I was not getting any Errors and even Warnings also.But o/p was not coming a black screen was displayed.
我的Xaml代码是
< phone:PhoneApplicationPage
&NBSP; x:Class =" Newsapp.MainPage"
&NBSP; xmlns =" http://schemas.microsoft.com/winfx/2006/xaml/presentation"
&NBSP; xmlns:x =" http://schemas.microsoft.com/winfx/2006/xaml"
&NBSP; xmlns:phone =" clr-namespace:Microsoft.Phone.Controls; assembly = Microsoft.Phone"
&NBSP; xmlns:shell =" clr-namespace:Microsoft.Phone.Shell; assembly = Microsoft.Phone"
&NBSP; xmlns:d =" http://schemas.microsoft.com/expression/blend/2008"
&NBSP; xmlns:mc =" http://schemas.openxmlformats.org/markup-compatibility/2006"
&NBSP; &NBSP; MC:可忽略= QUOT; d" d:DesignWidth = QUOT; 480" d:DesignHeight =" 768"
&NBSP; FontFamily =" {StaticResource PhoneFontFamilyNormal}"
&NBSP; FontSize =" {StaticResource PhoneFontSizeNormal}"
&NBSP; Foreground =" {StaticResource PhoneForegroundBrush}"
&NBSP; SupportedOrientations = QUOT;肖像" Orientation =" Portrait"
&NBSP;壳:SystemTray.IsVisible = QUOT;真" Loaded =" PhoneApplicationPage_Loaded">
&NBSP; <! - LayoutRoot是放置所有页面内容的根网格 - >
&NBSP; < Grid x:Name =" LayoutRoot"背景="透明">
&NBSP; &NBSP; &NBSP; < Grid.RowDefinitions>
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < RowDefinition Height =" Auto" />
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < RowDefinition Height =" *" />
&NBSP; &NBSP; &NBSP; < /Grid.RowDefinitions>
&NBSP; &NBSP; &NBSP; <! - TitlePanel包含应用程序的名称和页面标题 - >
&NBSP; &NBSP; &NBSP; < StackPanel x:Name =" TitlePanel"背景= QUOT;栗色" Grid.Row = QUOT; 0"保证金="12,17,0,28">
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < TextBlock x:Name =" ApplicationTitle"文本= QUOT; Teluguone" Style =" {StaticResource PhoneTextNormalStyle}" />
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < TextBlock x:Name =" PageTitle"文本= QUOT;办事指南"余量= QUOT; 9,-7,0,0" Style =" {StaticResource PhoneTextTitle1Style}" />
&NBSP; &NBSP; &NBSP; < / StackPanel>
&NBSP; &NBSP; &NBSP; <! - ContentPanel - 在此处添加其他内容 - >
&NBSP; &NBSP; &NBSP; < Grid x:Name =" ContentPanel" Grid.Row = QUOT 1 QUOT;保证金="12,0,12,0">
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < ListBox x:Name =" itemList">
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < ListBox.ItemTemplate>
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < DataTemplate>
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < StackPanel Margin =" 0,10,0,10">
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < TextBlock Text =" {Binding title}"字号= QUOT; 24英寸; TextWrapping = QUOT;包覆与QUOT; />
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < TextBlock Text =" {Binding pubDate}" />
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < TextBlock Text =" {Binding author}"字号= QUOT 18 QUOT; TextWrapping = QUOT;包覆与QUOT; />
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < / StackPanel>
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < / DataTemplate>
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < /ListBox.ItemTemplate>
&NBSP; &NBSP; &NBSP; &NBSP; &NBSP; < / ListBox>
&NBSP; &NBSP; &NBSP; < / Grid>
&NBSP; < / Grid>
< / phone:PhoneApplicationPage>
<phone:PhoneApplicationPage
x:Class="Newsapp.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="768"
FontFamily="{StaticResource PhoneFontFamilyNormal}"
FontSize="{StaticResource PhoneFontSizeNormal}"
Foreground="{StaticResource PhoneForegroundBrush}"
SupportedOrientations="Portrait" Orientation="Portrait"
shell:SystemTray.IsVisible="True" Loaded="PhoneApplicationPage_Loaded">
<!--LayoutRoot is the root grid where all page content is placed-->
<Grid x:Name="LayoutRoot" Background="Transparent">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<!--TitlePanel contains the name of the application and page title-->
<StackPanel x:Name="TitlePanel" Background="Maroon" Grid.Row="0" Margin="12,17,0,28">
<TextBlock x:Name="ApplicationTitle" Text="Teluguone" Style="{StaticResource PhoneTextNormalStyle}"/>
<TextBlock x:Name="PageTitle" Text="Latestnews" Margin="9,-7,0,0" Style="{StaticResource PhoneTextTitle1Style}"/>
</StackPanel>
<!--ContentPanel - place additional content here-->
<Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0">
<ListBox x:Name="itemList">
<ListBox.ItemTemplate>
<DataTemplate>
<StackPanel Margin="0,10,0,10">
<TextBlock Text="{Binding title}" FontSize="24" TextWrapping="Wrap" />
<TextBlock Text="{Binding pubDate}" />
<TextBlock Text="{Binding author}" FontSize="18" TextWrapping="Wrap" />
</StackPanel>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Grid>
</Grid>
</phone:PhoneApplicationPage>
页面后面的代码是
And code behind page is
Channel.cs类
Channel.cs class
Items.cs class
Items.cs class
请任何帮助
please any one help
任何帮助将不胜感激。我能理解为什么我没有错误和警告时没有显示o / p。
any help would be appreciated.I am uable to understand why o/p is not being displayed when i have no errors and warnings.
非常感谢。
推荐答案
这篇关于Xml序列化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!