How to restrict TShellTreeview to only display file and folders

Hi all, does anybody know a way of using the  TShellTreeview in delphi to display only regular files and folders, excluding the recycle bin, control panel etc, but including network files (but not the actual computers etc).

If not is there a suitable commercial/freeware robust component available.

This is driving me nuts, I know there has to be asimple solution to this!

Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Eddie ShipmanAll-around developerCommented:
You have to inherit from TShellTreeView and modify the Populate procedure to ignore the ones
you don't want to show.
Eddie ShipmanAll-around developerCommented:
You can also write an AddFolder event handler to ignore the ones you don't want:

procedure TForm1.ShellTreeView1AddFolder(Sender: TObject;
  AFolder: TShellFolder; var CanAdd: Boolean);
  if (AFolder.DisplayName = 'Recycle Bin') or
     (AFolder.DisplayName = 'My Documents') then
    CanAdd := False;

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.