Looks like there is some permissions problem on the c:\development\MyProject directory. Was that directory, by and chance, created by another user (or while you were logged in as another user, such as an admin user)? If so, you might not have access to it. Check the security settings and give your account full rights to the c:\development directory and all its subdirectories.
I am logged in as a user with Administrator privileges. Is there another way around this or what else can I do?
I only use one login on this laptop so I would think I created the directory as the same user I am now.
I just hit this problem again tonight; last week somehow I got around it, but it was not straightforward so I don't remember how it happened
if I even knew at the time. I just kept trying things. Doesn't seem like it has to be so challenging to add a jar to the build path!
When I look at Properties on this folder, I see that the user name I am logged in as has Full Control; wouldn't that work?
I have turned off UAC and still cannot add a jar to the BuildPath through MyEclipse .
Had to do a "clean" on the project. Thanks for your help. I had added full control to every user I had and still I could ot get rid of the compile problem. I have Eclipse set to automatically build after changes, but it doesn't seem to always do a clean when it needs to. Thought of that when I went to bed at 3 a.m. last night. Clear thinking sometimes means to get away from the work. I should know that.
I am able to use log4j; but I'm not certain how I have it included in the CLASSPATH. I added it to the Environment Variables and also dropped it in WEB-INF/lib folder. I still can't add it through the Project-> Properties- Java Build Path method. I feel like it does have to do with the permissions on the log4j.jar file. I have only logged in as one user so the permissions should be the same on that jar as on mail.jar and jstl-1.2.jar which I can add to the project this way.
Adding the logj4 JAR file to the project libraries should not involve anything in regards to the log4j.jar file itself - all that action really does is add a line to the .classpath file.
Oh no, I just had a thought! It could very well be that the file is in use. Can you temporarily turn off your virus scanner? It could well be that the virus scanner has the file open and thus Eclipse cannot update it. (I have a similar problem with by daily backup - I close Outlook but the backup cannot copy the PST files because the virus scanner is busy scanning them. I have to wait a few minutes to let the scanner run its course, then let the backup run.)
Another way to track whether the file is in use is to get File Monitor or System Monitor from sysinternals. Set it up to monitor only the .classpath file. That should tell you if some other task is accessing the file.
Also, what Eclipse plugins do you have? It could be that a plugin has an extra thread that has that file open, thus preventing it from being updated by other threads. At least, I think that would happen.
I had this exact same problem. After hours of frustrating attempts to find out what was causing this, I stumbled across a fix.
It seems that Eclipse can't write to files with the 'hidden' attribute set. For some reason my .classpath and .project files had the "hidden" attribute set.
(No doubt some helpful process or other thought that because they started with '.', they should be hidden)
Unsetting the "hidden" attribute fixed the problem. ("attrib /s -h" in your workspace directory for those who like the command line)