Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

°ÑdatatableÀïµÄÊý¾Ýת»»³Éxml¸ñʽµÄ×Ö·û´®

string GetXmlByDataTable()
    {
        string xmlstr;
        string sql = "select top 10 * from BasicInfo";
        DataTable dt = idb.ReturnDataTable(sql);
        dt.TableName = "tbname";
        if (dt.Rows.Count>0)
        {
            System.IO.StringWriter writer = new System.IO.StringWriter();
            dt.WriteXml(writer);
            xmlstr = writer.ToString();
        }
        return xmlstr;
    }


Ïà¹ØÎĵµ£º

VSÖÐʹÓÃTinyXml²Ù×÷xmlÎļþ

µ½http://sourceforge.net/projects/tinyxml/ÏÂÔØTinyXmlµÄ¹Ù·½Àý×Ó£¬
ÀïÃæÓкü¸¸öÎļþ£¬ÎÒÃǰÑ
tinyxml.h
tinystr.h
tinystr.cpp
tinyxml.cpp
tinyxmlparser.cpp
tinyxmlerror.cpp
Õ⼸¸öÎļþ°üº¬µ½ÎÒÃǵŤ³ÌÄÚ¡£
Òª°üº¬Í·Îļþ #include "tinyxml.h"
ÕâÓþͿÉÒÔ¿ªÊ¼Ê¹ÓÃtinyxml¿ªÊ¼²Ù×÷xmlÎļþÁË£¬¾ßÌåµÄ²Ù×÷· ......

¹ØÓÚXMLÖÐ×Ö½ÚдÈëÁ÷×Ö¶ÎʱµÄ˵Ã÷

·½·¨Ò»£º
      ²ÉȡͨÓõÄbase64±àÂ뷽ʽ£¬È¡Ê±½âÂë´æÊ±¼ÓÂë¡£
ëÀÏʦÌṩÁËÍêÕûµÄ±àÂë´úÂ룬ÇÒЧÂʺܸߡ£
unit Base64;

interface

uses SysUtils, Classes;

type
{$IFDEF UNICODE}
Base64String = AnsiString;
{$ELSE}
Base64String = strin ......

JAVA¶ÔÏóת»»ÎªXML¸ñʽ

JAVA¶ÔÏóת»»ÎªXML¸ñʽ
    ¼òµ¥µÄ²üÊöÏÂÈçºÎ½«JAVA¶ÔÏóת»»ÎªXML¸ñʽ£¬ÏêϸÁ˽âÇë½øÈëhttp://xstream.codehaus.org/tutorial.html
  
 JAVABEAN¶ÔÏó
 
  userInfo.java
         private String name;
   & ......

Integration with the XML Data Type

Integration with the XML Data Type
With the introduction of the XML data type, we wanted to also give FOR XML the ability to generate an instance of XML directly (more precisely, it generates a single row, single column rowset where the cell contains the XML data type instance).
Because of the bac ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ