可用于测试的数据
一.本机字体
System.Drawing.Text.InstalledFontCollection MyFont = new System.Drawing.Text.InstalledFontCollection(); var v = MyFont.Families;
二.本机文件及文件夹
DirectoryInfo[] dirs = new DirectoryInfo(@"d:\Documents").GetDirectories();
var query = from d in dirs
where (d.Attributes & FileAttributes.System) == 0
select new
{
DirectoryName = d.FullName,
Created = d.CreationTime,
Files = from f in d.GetFiles()
where (f.Attributes & FileAttributes.Hidden) == 0
select new { FileName = f.Name, f.Length, }
};
三.本机所有进程
var v = System.Diagnostics.Process.GetProcesses();