问题描述
我正在我的应用程序中使用WebBrowser控件
WebBrowser导航到URL
http://feeds.bbci.co.uk/news/rss.xml [ ^ ]
一旦WebBrowser的Document Completed事件被触发,我将通过MessageBox.s(WebBrowser1.DocumentText)显示源代码;
看来显示的源代码与实际的不同
显示的代码包含html标签,其中url是XML文件的
我需要的是与XML中相同的文本
要记住的一件事是,我确实需要使用webbrowser控件,我尝试了httpwebrequest,webclient等都无法正常工作,只有webbrowser能够获取XML页面,但是它将其呈现为HTML,所以我无法获取实际的xml
希望获得soem帮助.
i am using WebBrowser Control in my application
the WebBrowser Navigates to the url
http://feeds.bbci.co.uk/news/rss.xml[^]
once the Document Completed Event of WebBrowser is Fired, i am showing the source code by MessageBox.s(WebBrowser1.DocumentText);
by it appears that the shown source code is different than actual
shown code contains html tags where as the url is of an XML file
what i need is the same text as it is in XML
one thing to remember, i do need to use webbrowser control, i have tried httpwebrequest, webclient etc none work, only webbrowser is able to get the XML page but it renders it to HTML so i cant get actual xml
hoping to get soem help
推荐答案
这篇关于WebBrowser控件的原始源代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!