File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java in General and the fly likes Simple Question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "Simple Question" Watch "Simple Question" New topic

Simple Question

Angelo Watson
Ranch Hand

Joined: Oct 27, 2002
Posts: 39
Is it possible to create a folder on a windows desktop and when a user double clicks on it, it will prompt the user a password.
Please Help.
Philip Shanks
Ranch Hand

Joined: Oct 15, 2002
Posts: 189
Two things:
(1) What's this got to do with Java?
(2) I don't think it's possible.
I think you might approximate this behavior on a Windoze NT/2K/XP machine by the following rather convoluted means:
a. create a hidden folder (weakest link in the chain -- if you simply set permissions on this, then the user isn't prompted for anything. They just get access or denied.)
b. create a share to the hidden folder only available to specific localhost or domain users
c. mount the share on a drive letter (this is where it gets dicey)
d. create a link to that drive -- this is the thing that users will double-click on, and possibly get prompted with a "connect-as" prompt.
If this works (and I make no guarantees!) the link should appear to be a folder with restricted access properties that might produce a prompt.
Disclaimer: I am a Linux user. I make absolutely no claims to know how to do anything in a Windoze environment, nor do I know why anyone would want to do anything in such an environment.

Philip Shanks, SCJP - Castro Valley, CA
My boss never outsources or has lay-offs, and He's always hiring. I work for Jesus! Prepare your resume!
I agree. Here's the link:
subject: Simple Question
It's not a secret anymore!