Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/csharp-4.0/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 4.0 如何在WindowsPhone7中使用web浏览器控件从xml文件中获取html文件?_C# 4.0_Xml Parsing_Linq To Xml_Webbrowser Control - Fatal编程技术网

C# 4.0 如何在WindowsPhone7中使用web浏览器控件从xml文件中获取html文件?

C# 4.0 如何在WindowsPhone7中使用web浏览器控件从xml文件中获取html文件?,c#-4.0,xml-parsing,linq-to-xml,webbrowser-control,C# 4.0,Xml Parsing,Linq To Xml,Webbrowser Control,您好,我正在使用xml文件。我想显示数据web视图。如何在windows phone 7中获取web视图 <Articles> <articles title="photos"> <Description> Hottie Mallika Sherawat speaks about the men whom she’s over the moon about </Description>

您好,我正在使用xml文件。我想显示数据web视图。如何在windows phone 7中获取web视图

<Articles>
   <articles title="photos">
       <Description>
          Hottie Mallika Sherawat speaks about the men whom she’s over the moon about
       </Description>
       <Fullcontent>
          <style> img {padding:2px;} </style><p> <img alt="Mallika Sherawat" pimcore_disable_thumbnail="true" pimcore_id="5853" pimcore_type="asset" src="http://dev2.mercuryminds.com/bolly/feb2013/bolly---mallika-sherawat-s-upcoming-movie-dirty-politics/90_mallika-sherawat_bolly.jpg" style="width: 500px; height: 370px; float: left;" /></p>
          <p> Actress Mallika Sherawat is all set to begin shooting for&nbsp;<em>Dirty Politics</em>&nbsp;where she plays Bhanwari Devi, a nurse whose murder hit the headlines last year. Meanwhile, she gets talking on&nbsp;Hollywood where she has not really had any meaty roles. She does not seem to care though. “It’s not important to play full length roles. Being recognised for playing whatever I did makes me feel proud.”&nbsp;</p>
       </Fullcontent>
     </articles>
     <articles> 
        <Description> 
           <p> Legendary singer <strong>Asha Bhosle</strong> has added yet another feather to her cap with her acting debut in Mai. She plays the lead role of a woman abandoned by her son. 
        </Description> 
        <Fullcontent> 
          <div id="container" class="cf"> 
           <link rel="stylesheet" href="http://dev2.mercuryminds.com/imageslider/app/css/demo.css" type="text/css" media="screen" />
           <link rel="stylesheet" href="http://dev2.mercuryminds.com/imageslider/app/css/flexslider.css" type="text/css" media="screen" />
           <div id="main" role="main"> <section class="slider"> 
           <div class="flexslider"> 
           <ul class="slides">
             <li>Sonam Kapoor<img src="http://dev2.mercuryminds.com/website/var/tmp/thumb_5814_1_sonam-kapoor_01feb2013__appfeed.jpeg" alt="Sonam Kapoor"/></li> 
             <li>Sridevi<img src="http://dev2.mercuryminds.com/website/var/tmp/thumb_5815_2_sridevi_01feb2013__appfeed.jpeg" alt="Sridevi"/></li> 
        </Fullcontent> 
     </articles> 
 </Articles>

辣妹玛莉卡·谢拉瓦特谈到了她最喜欢的男人
img{padding:2px;}

女演员马丽卡·谢拉瓦特(Mallika Sherawat)准备开始拍摄肮脏政治片,她在片中饰演护士班瓦里·德维(Bhanwari Devi),去年她的谋杀案成为头条新闻。与此同时,她开始谈论好莱坞,在那里她并没有真正扮演过任何有意义的角色。但她似乎并不在意。“扮演完整角色并不重要。无论我做了什么,都能得到认可让我感到自豪。”

传奇歌手Asha Bhosle在Mai的首次表演为她的帽子又添了一层光彩。她扮演一个被儿子遗弃的女人。
  • 索纳姆·卡普尔
  • Sridevi

我想使用windows phone 7的web浏览器控件在xml文件的Fullcontent标记上显示web视图。请帮助我找到一个…,谢谢您的帮助。

您可能可以将此作为起点

从XML创建html字符串后,可以执行以下操作

webBrowser1.NavigateToString(html); 
对于处理XML文件,因为这只是一个基本的XML文件,所以您可以这样做

    var xDoc = XDocument.parse("[YOUR XML STRING]");
    var articles = xDoc.Root.Elements("articles").select(e=>new {
     desc = e.Element("Description").Value,
     fullContent = e.Element("FullContent").Value

});

您好,谢谢您的重播,我希望您的答案,但我想动态绑定fullcontent。我想您在本地系统中存储了一个html文件,然后您就可以获得资源流了吧?但这里不是这样,我将直接从xml文件获取。如果你知道,请帮助我…,提前谢谢。这样你可以使用任何xml文件。前提是xml文件的格式正确。。如果你正在寻找什么,请更新你的问题