using System;
using Shell32;
Code:
static void Main()
{
Shell shell = new Shell();
// open dialog for desktop folder
// use appropriate constant for folder type ShellSpecialFolderConstants
Folder folder = shell.BrowseForFolder(0, "folderPath/FilePath",0 ,ShellSpecialFolderConstants.ssfDESKTOP); if (folder != null)
{
foreach (FolderItem fi in folder.Items())
{
Console.WriteLine(fi.Name);
}
}
}
0 comments:
Post a Comment