Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: I cannot delete a particular file Access Denied

27 Oct 2013   #1
blockie

 
I cannot delete a particular file Access Denied

I am tryiong to save, delete or overwrite the file "Clear Print Spooler.bat" in C;\windows\system32 and in each case get "ACCESS Denied" error. I have tried the above in the command window with admin. priviledge. Same error.

I had added a line that contained the word "Runas". Now I try to remove that line and save the file and get the error. On my other computer which the bat file has not been altered I can edit,save,copy move,delete and overwrite without the error. I think if I can edit the file to remove the extra line and then save it, I could remove the error.
Bill


My System SpecsSystem Spec
.

27 Oct 2013   #2
jeepmann4x4

Windows 7 Ultimate 64bit
 
 

What all have you tried so far? Will it let you change the file type to .txt ? How about making a 2nd bat file but give it the same name, (make it in a different folder) then copy it to where the bad one is? (win7 should try to overwrite the old with the new .bat file.
My System SpecsSystem Spec
27 Oct 2013   #3
UsernameIssues

W7 Pro SP1 64bit
 
 

Files in that folder are usually owned by a Windows account named Trusted Installer. If some application installed that batch file into that location, then maybe it should stay there. If you put it there, then take ownership of the file and move it to another location - maybe the public desktop.

If you must leave it in that folder, then you can still take ownership of the file so that you can edit it.
My System SpecsSystem Spec
.


28 Oct 2013   #4
blockie

 

This problem was on another computer, so this is what I did using the suggestions you guys provided.
I change folder/file options so that the extension was available. and changed the extension to txt.
I then deleted the file.
On my computer I changed the extension to txt and copied the file to a flash drive. Changed the extension on my computer back to bat.
On the other computer I copied the file from the flash drive to the system32 folder.
I took ownership of the file and changed it back to bat.
I then made a shortcut and placed the shortcut on the desk top.Original problem solved.

One problem remains,
The shortcut I place on the desktop is in several non-administrative user accounts. When they use the shortcut to clear the print spooler they run it as the administrator and then have to use my password.
Understandingly, I am reluctant to give up my password. Anyway out of this?
Bill
My System SpecsSystem Spec
28 Oct 2013   #5
UsernameIssues

W7 Pro SP1 64bit
 
 

I don't have a solution for the admin password issue, but I would like to ask why your users have to clear the printer cache so often that you felt the need to create/deploy this batch file? Just wondering?
My System SpecsSystem Spec
28 Oct 2013   #6
blockie

 

The reason I need this is that I am maintaining this computer in an Assisted Living Facility and although I have several user accounts that are password protected I have one account for general use of any resident. The general use account is the one that piles up print jobs in the printer spooler. Apparently those users keep trying to print when the printer is off, out of paper or has some kind of error. Then another user comes along, corrects the printer problem and then tries to print a document. Because the spooler already has jobs ahead of them they must print multiple times before their print job is printed. Ergo,the clear spooler command.
Bill
My System SpecsSystem Spec
28 Oct 2013   #7
UsernameIssues

W7 Pro SP1 64bit
 
 

Is the general use account a standard user or the Windows Guest account?

There are a few things that I would like to test before I mention them.

If I don't post something in a day or two - send me a PM or bump this thread.
My System SpecsSystem Spec
30 Oct 2013   #8
UsernameIssues

W7 Pro SP1 64bit
 
 

I've run out of things to try - nothing worked for me :-(

Maybe other forum members have an idea.
My System SpecsSystem Spec
Reply

 I cannot delete a particular file Access Denied




Thread Tools





Similar help and support threads
Thread Forum
Can't delete folder - access denied
Hello! I have a small issue concerning deleting folder. Here's situation: I had a folder that I wanted to delete. I used shift+del combo for instant deletion, but than issue occured. Basicly, folder stayed, yet files deleted themselves. And when I try to delete the folder, it says I need...
General Discussion
Can't delete folder - access denied (despite attempts to fix)
I'm trying to delete an obsolete directory. When I try to do so, I get a message "Folder access denied: You require permission from Administrators to make changes to this folder." Based on forum advice for a similar problem that worked in the past, I did the following: Right-click the...
System Security
Trying to delete a primary partition in diskmanagement - Access Denied
I have confirmed that I have admin privileges. The HDD in question is a small 80gb HDD with a 75 gb primary partition. When trying to delete the partition with diskmanagement or diskpart, it just says Access Denied. Currently I can not provide a screenshot, not for the next couples of hours. ...
General Discussion
Can't delete a file - Access is denied
Hi, I have a compiled .dll file that I want to delete - but I can't do it in any way. I already tried del command line and take ownership (both GUI and cmd) but nothing helped so far. I always get the Access is denied error. Any idea will be appreciated! Thanks, Shaorn
General Discussion
Trying to Delete Program Files, Access Denied
This entire morning thus far I've been attempting to delete files from Norton Internet Security, which has been inactive for a long time (we are not going to renew our account) and has been bugging us constantly. I assumed it would be an easy task, and I couldn't have been farther from the truth. ...
General Discussion
Unable to Delete Folder from Desktop: Access Is Denied?
I had a folder on my Desktop that just won't delete. It was apparently being shared with my Xbox360. I right-clicked it, pressed Delete, and it said it was being shared and if I was sure I wanted to do it anyways. So, of course, I said Yes. It deleted everything within the folder, yet the folder...
Software

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 13:57.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App