資源簡介
讀寫xml文件
代碼片段和文件信息
using?System;
using?System.Collections.Generic;
using?System.ComponentModel;
using?System.Data;
using?System.Drawing;
using?System.Linq;
using?System.Text;
using?System.Threading.Tasks;
using?System.Windows.Forms;
using?System.xml;
namespace?xmlread
{
????public?partial?class?Form1?:?Form
????{
????????xmlDocument?doc;
????????public?Form1()
????????{
????????????InitializeComponent();
????????}
????????private?void?button1_Click(object?sender?EventArgs?e)
????????{
????????????doc?=?new?xmlDocument();
????????????xmlReaderSettings?settings?=?new?xmlReaderSettings();
????????????settings.IgnoreComments?=?true;
????????????string?filepath?=?Environment.CurrentDirectory;
????????????filepath?+=?“\\book.xml“;
????????????xmlReader?reader?=?xmlReader.Cr
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2019-05-11?14:11??xm
?????目錄???????????0??2019-05-11?14:11??xm
?????文件?????????187??2019-05-08?22:12??xm
?????文件????????7399??2019-05-12?09:03??xm
?????文件????????4025??2019-05-12?09:03??xm
?????文件????????5817??2019-05-12?09:03??xm
?????文件?????????519??2019-05-08?22:12??xm
?????目錄???????????0??2019-05-11?14:11??xm
?????文件????????1334??2019-05-08?22:12??xm
?????文件????????2866??2019-05-08?22:12??xm
?????文件????????5612??2019-05-08?22:12??xm
?????文件????????1094??2019-05-08?22:12??xm
?????文件?????????249??2019-05-08?22:12??xm
?????目錄???????????0??2019-05-11?14:11??xm
?????目錄???????????0??2019-05-11?14:11??xm
?????文件????????1041??2019-05-09?00:12??xm
?????文件???????13312??2019-07-05?15:45??xm
?????文件?????????187??2019-05-08?22:12??xm
?????文件???????34304??2019-07-05?15:45??xm
?????文件???????22984??2019-07-05?15:48??xm
?????文件?????????187??2019-05-08?22:12??xm
?????文件?????????490??2019-03-19?12:46??xm
?????文件????????1169??2019-05-08?22:10??xm
?????文件????????1169??2019-05-08?22:10??xm
?????目錄???????????0??2019-05-11?14:11??xm
?????目錄???????????0??2019-07-05?15:45??xm
?????文件????????1308??2019-07-05?15:45??xm
?????文件????????6919??2019-05-11?14:11??xm
?????目錄???????????0??2019-07-05?15:49??xm
?????文件???????????0??2019-05-08?22:12??xm
?????文件???????????0??2019-05-08?22:12??xm
............此處省略12個文件信息
- 上一篇:dxf文件解析工具c#源碼
- 下一篇:c#大文件分片上傳demo
評論
共有 條評論