zoukankan      html  css  js  c++  java
  • c# 代码创建xml文件

        /***创建文件***/

    给xml添加"<?xml version="1.0" encoding="gb2312"?> "格式:
    XmlDocument xmldoc = new XmlDocument( ) ;
        XmlDeclaration   xn   =  xmldoc.CreateXmlDeclaration("1.0","gb2312",null);  
        xmldoc.AppendChild(xn);

    最后创建好的xml文件:
    <?xml version="1.0" encoding="gb2312"?>
    <myinfo>
      <user>
       ***
      </user>
    </myinfo>
  • 相关阅读:
    C++ and OO Num. Comp. Sci. Eng.
    C++ and OO Num. Comp. Sci. Eng.
    C++ and OO Num. Comp. Sci. Eng.
    C++ and OO Num. Comp. Sci. Eng.
    C++ and OO Num. Comp. Sci. Eng.
    C++ and OO Num. Comp. Sci. Eng.
    WPF 应用程序使用程序的模型视图 ViewModel 设计模式 WVVM
    穿透Session 0 隔离(二)(How to use Windows service run a GUI application.)
    穿透Session 0 隔离(一)(how to use Windows service run a GUI application.)
    .Net 远程路径权限访问。
  • 原文地址:https://www.cnblogs.com/flashicp/p/787188.html
Copyright © 2011-2022 走看看