コード例 #1
0
ファイル: Form1.cs プロジェクト: Tenurian/File-Explorer-2.0
 private void btnSearch_Click_1(object sender, EventArgs e)
 {
     DirectoryInfo d = new DirectoryInfo(txtDirectory.Text);
     SizeGetter sg1 = new SizeGetter();
     TreeNode t = trvDirectories.Nodes.Add(d.FullName, d.Name + " (" + (int)sg1.GetDirectorySize(d.FullName) / 1000 + "K)");
     Digger digger = new Digger();
     digger.Dig(d, this);
 }
コード例 #2
0
ファイル: Program.cs プロジェクト: Tenurian/File-Explorer-2.0
 public FileExplorerConsole()
 {
     //String foldername = @"C:\Users\Tenurian\Tester";
     String foldername = @"C:\Users\Tenurian\Documents\Visual Studio 2015\Projects\FileExplorerConsole";
     Digger digger = new Digger();
     spacers.Add(foldername, 1);
     DirectoryFound(new DirectoryInfo(foldername)); //this is here to ensure the top folder appears
     digger.Dig(new DirectoryInfo(foldername), this);
     Console.ReadLine();
 }