Click here to Skip to main content
15,885,216 members
Articles / Programming Languages / XML

Enhanced BrowseForFolder Styled TreeView

Rate me:
Please Sign up or sign in to vote.
4.86/5 (85 votes)
27 May 2013Apache5 min read 578.2K   16.8K   269  
Supports Explorer, SingleChecked and RecursiveChecked mode (checkboxes). Lets you specify the displayed drive types, etc...
using System;

namespace Raccoom.Win32
{
	/// <summary>
	/// Summary description for Shell32Namespaces.
	/// </summary>
	public class Shell32Namespaces
	{
		#region fields
		private Shell32.Shell _shell;
		#endregion

		#region public interface
		public Shell32.Folder GetDesktop()
		{
			return Shell.NameSpace(Shell32.ShellSpecialFolderConstants.ssfDESKTOP);			
		}
		public Shell32.FolderItems GetEntries(Shell32.ShellSpecialFolderConstants shellFolder)
		{
			
			Shell32.Folder shell32Folder = Shell.NameSpace(shellFolder);
			return shell32Folder.Items();
		}
		#endregion				

		#region internal interface
		internal Shell32.Shell Shell
		{
			get
			{
				// create on demand
				if(_shell==null) _shell = new Shell32.ShellClass();				
				return _shell;
			}
		}
		#endregion		
	}
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Apache License, Version 2.0


Written By
Software Developer (Senior)
Switzerland Switzerland
My interest is in the future because I am going to spend the rest of my life there. (Charles Kettering)

Biography

  • 1996 - 1998 PC Board PPL, HTML, DHTML, Javascript and ASP
  • 1999 - 2001 coding Centura against Sql Database (SqlBase,MSSQL,Oracle)
  • 2002 - 2004 C# Windows Forms
  • 2005 - 2006 C# ASP.NET, Windows Forms
  • 2006 - 2009 C#, WCF, WF, WPF
  • 2010 - 2012 C#, Dynamics CRM, Sharepoint, Silverlight
  • 2013 - 2013 C#, WCF DS (OData), WF, WPF
  • 2014 - 2016 C#, Azure PaaS, Identity, OWIN, OData, Web Api
  • 2017 - now C#, aspnet.core, IdentityServer4, TypeScript & Angular @ Azure IaaS or PaaS

Interests

  • family & friends
  • chilaxing ,)
  • coding

Comments and Discussions