Solved

Hide Folder

Posted on 2001-08-23
7
1,698 Views
Last Modified: 2008-03-17
Hi!

For example. If I want to hide D:/Projects

Is it possible in delphi?
0
Comment
Question by:SULTAN
7 Comments
 
LVL 6

Accepted Solution

by:
Stuart_Johnson earned 30 total points
ID: 6420138
Hi Sultan,

This will set the attributes of the folder to hidden:

SetFileAttributes('D:\Projects', FILE_ATTRIBUTE_HIDDEN);

Be aware that the folder is still "visible" if Explorer is told to show hidden files.

Cheers,

Stu.
0
 
LVL 6

Expert Comment

by:Jaymol
ID: 6420147
The only way I've found to succesfully hide something in Windows is to move it into a subdirectory of the windows font directory.

eg.. (on WinNT) To hide directory "D:\Projects", move it to "C:\WinNT\Fonts\Projects"

Although this isn't ideal as it isn't really hiding it, and it will show up with a "Find files or folders.." type search, it doesn't show up in "My Computer", no matter what the view options are set to.

Alternatively, if you can get away without doing it in Delphi, have a look at a program called "Magic Folders" which can be found at...

           http://www.pc-magic.com/

It does what you ask, but I don't know how.

Hope this helps,

John.
0
 
LVL 1

Expert Comment

by:Dennis9
ID: 6421815
Hi.
There is a place in the registry that u can edit so the folder get invisible - but i just don't know where :<

Dennis
0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 7

Expert Comment

by:Rob Siddell
ID: 6422783
I will do some reading in my registry book to see if i can find something on making folders invisible.

Rob
0
 
LVL 7

Expert Comment

by:Rob Siddell
ID: 6422848
Well i could tell you how to remove the option to see hidden files/directories and to set the option via your program and what not and how to restore the option, but i'm not seeing how to make it invisible. I will keep looking though.

Rob
0
 

Author Comment

by:SULTAN
ID: 6442517
Good work!

Thanks, SULTAN
0
 
LVL 6

Expert Comment

by:Stuart_Johnson
ID: 6443212
Cheers Sultan.

Stu.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question