当前位置:首页 » 软件开发
开发技术指南» 文章正文
    引言: HOW TO: Read XML Data fr
 

 

 ·.net使xml串行化易如反掌    »显示摘要«
    摘要: 人们一直高喊xml是解决系统互联问题的关键, 而.net framework 也为处理xml数据提供了许多不同的类库. xmldocument 类能让你像处理文件一样处理xml 数据, 而xmlreader, xmlwriter, 和它们的派生类使你能够将xml 数据做为数据流处理. xmlserializer 则提供了另外的方法, 它使你能够将自己的对象串行和反串行化为xml. ......
    摘要: using system; using system.componentmodel; using system.data; using system.xml; namespace system.data.xmlclient { public class xmlcommand : component, idbcommand, icloneable { // construc......


HOWTO:ReadXMLDatafromaStream
how to: read xml data from a stream this article discusses a beta release of a microsoft product. the information in this article is provided as-is and is subject to change without notice. no formal product support is available from microsoft for this beta product. for information about obtaining support for a beta release, please see the documentation included with the beta product files, or check the web location from which you downloaded the release. -------------------------------------------------------------------------------- the information in this article applies to: microsoft .net development platform (ndp) beta 2 -------------------------------------------------------------------------------- in this task summary requirements how to read xml data from a stream references summary this article demonstrates how to use the xmltextreader class to read extensible markup language (xml) from a stream. the stream can come from a variety of sources, such as a byte stream from a server, a file, or a textreader class. back to the top requirements the following list outlines the recommended hardware, software, network infrastructure, and service packs that you will need: microsoft windows 2000 professional, windows 2000 server, windows 2000 advanced server, or windows nt 4.0 server microsoft visual studio .net this article assumes that you are familiar with the following topics: xml terminology creating and reading xml how to read xml data from a stream open visual studio .net. create a new microsoft visual basic (vb) or microsoft visual c# console application. note : the following steps provide a detailed description of how to build the application. you can also go directly to step 10, where completed code is provided. make sure that the project contains a reference to the system.xml and system.io namespace. use the imports statement on the xml namespace so that you are not required to qualify xmltextreader declarations in that namespace later in your code. you must use the imports statement prior to any other declarations as follows: visual basic .net code imports system.xml imports system.io visual c# code using system.xml; using system.io; create or retrieve the xml stream. a stream is an abstract representation of an input or output device that is the source of, or destination for, data (in this case, xml data). you can write to and read from a stream, which is best visualized as a flow of bytes. streams are used to provide independence from the device and therefore require no program changes if, for example, the sou
...   下一页
 ·xmlconnection    »显示摘要«
    摘要: using system; using system.componentmodel; using system.data; using system.xml; namespace system.data.xmlclient { public class xmlconnection : component, idbconnection, icloneable { // co......
» 本期热门文章:

©2000-2007 All Rights Reserved. 最佳浏览:1024X768 MSIE