A folder opened in another program cannot be deleted. How to delete a file opened in another program using Unlocker

Hi all! Today I will tell you Howdelete a file or folder that cannot be deleted in different ways, in case you have already tried everything you could, but it still didn’t help. I decided to write this article because I myself once encountered a similar problem, that my design themes that were in the folder did not want to be deleted or moved. Why, they couldn’t even be opened or renamed.

Often when PC users try to delete such files, The following messages may appear: the file cannot be deleted, access is blocked, the disk may be full or write-protected, the file is occupied by another application, this process is busy, the folder is not empty. These errors occur for many different reasons, which you must first understand and understand what the problem may be before you try to do anything. So, there are not many reasons for this, here are some of them:

— You are trying to delete a file that is used by other programs. For example, if you were watching a movie or listening to music, but before you had time to close the player, you are already trying to delete the file being played, then no matter how hard you try, you will not be able to do this until you close all the corresponding applications that use this file in the PC ( Personal Computer). It also sometimes happens that this file or folder is used by other applications, but you do not see them, although they are displayed in the task manager, which will be discussed below.

— You are trying to delete a file that is used by other users. For example, you downloaded it through a torrent tracker and then wanted to delete it, but for some reason it just doesn’t want to be deleted. The thing is that another user is downloading this game from you over the Internet, and until you turn off the Internet or exit the torrent program, the file will not be deleted.

-You don't have enough rights to do this. What does this even mean? Am I the owner of my computer or who? The fact is that you probably, like me once, could have placed your files or folders in folders of the Windows operating system, to which access is denied for your own safety. This restriction was created to prevent you from ruining your computer by deleting some important file from the Windows operating system.

— Files or folders that you wanted to delete were quarantined by your antivirus program. In other words, your antivirus program didn’t like something about them, so it blocked them so that they could not harm your PC in any way.

Ok, we figured out the reasons. Now all that’s left for you to delete your non-deletable file is to simply try all the methods that I described for you below.

How to delete a file or folder that cannot be deleted via a computer?

Method 1. Just restart your computer, in most cases this will be enough.

Method 2. Turn on task manager. Press Ctrl + Alt + Delete if you have Windows 7 or XP and Windows + X if you have Windows 8. A window will appear in front of you, go to “processes”.

All programs that are currently running on your computer will be displayed here. Try to find exactly the one that might use your file. If it doesn’t work, then just select any one at random and click “end process” each time trying to delete the file again.

Method 3. Turn off your computer and turn it on again. During the boot process, press the F8 key many times. A black screen will appear in front of you, where there will be several options to boot your PC. Select "safe mode". As soon as the computer boots, try to delete the file or at least move it to another location.

Method 4. If the file is simply not deleted, but can be transferred, then you can proceed as follows. Just drag your file onto an empty flash drive and format it. Be careful, after this process everything will be deleted from it!

Method 5. Open your computer and find your non-deletable file on the desktop. At the top of the window, click “service”, then “folder options”, go to the “view” tab and uncheck the box if it is next to “use simple file sharing” and save the changes. Try deleting your file or folder.

Method 6. Change administrator rights. Right-click on our file, select “property”, then in the window that opens “security” and click “advanced”.

Another window will appear, click on “owner”. Here simply select another administrator and click “apply”. Personally, this operation helped me remove restrictions from my WordPress templates, which I wrote about.

Method 7. Disable all processes associated with this file. This procedure is very similar to the task manager, but it has a more effective effect. Click "start" on your desktop, then "run". In the window that appears, enter msconfig and press OK.

Another window will appear in front of you. Here go to the “startup” tab and in the list of running processes try to find the name of your non-deletable file and uncheck it, and click ok.

How to delete files and folders that cannot be deleted using special programs?

Method 8. To solve this problem, a very cool and at the same time simple program “UnLocker” was created a long time ago, which is capable of deleting files that cannot be deleted in 90% of cases. You can download the program from the official website. During the installation process, be careful and uncheck the box where you are offered to install another application in addition to the program. If you don’t do this, then at the end of the installation your antivirus program will swear for a long time.

If you don’t know how to delete a folder that cannot be deleted, then our material will help you figure it out.

Everyone periodically deals with “undeletable” folders on their PC.

It is stupid to blame anyone for this, even the system that tells us that a given directory is currently occupied by some process.

As a result, all liquidation manipulations end in fiasco. Let's get to the main topic: how to delete a folder that cannot be deleted on windows 7 (win8)?

There are 5 options to solve the problem:

  • System check;
  • Viruses;
  • Folder settings;
  • Third party utilities.
  • Let's try to figure out the situation.

    Reboot

    So, you intend to delete the ill-fated directory, but the system claims that it cannot do this for one reason or another. The main reason is that files in the folder are being used by some application or process that is currently running.

    The example shows that it is impossible to liquidate the “screenshots” folder, since one or more files are currently being used by one of the Windows programs. Since most people don’t know which one it is, they have no choice but to restart the machine.

    Click “Start” (1), then click on the small square (2) next to the “shutdown” button. Select the item with reboot (3).

    System check

    If you do not want to restart, but decide to get to the bottom of the truth, check if the application currently running is in the folder.

    Let's say you decide to get rid of Skype for some reason, not by uninstalling, but by barbarously deleting the folder in which all the contents of the program are located. Let's consider this option.

    First, let's open the folder. We follow the path: Drive C – Program Files – Skype.

    We see this picture.

    And this is what the system produces if you press “Delete” on the keyboard.

    Firstly, the program is running, so the ability to uninstall is blocked by the system. Secondly, it “hangs” in the task manager, namely in processes.

    You need to close the program and, just in case, “kill” the process so that the notification does not appear again.

    Exit Skype, then press Ctrl+Alt+Delete (task manager) and select the program. After that, click on the “end process” button.

    A window will appear confirming your intentions. Click again to complete. Now you know how to delete a folder that cannot be deleted on Windows 8 and other versions of the OS.

    Note! The above procedure is equally useful for all such cases, not just for Skype.

    Viruses

    In some cases, deleting a directory is impossible for the simple reason that potentially unwanted software has entered the PC, i.e. viruses. In addition to the Internet, they can get to your computer via a flash drive.

    How to delete a folder that is not deleted from the flash drive? That's right, by preliminary scanning with an antivirus.

    Open the antivirus and scan the drive. Then we try to delete the folder. If that doesn't work, you'll have to format the flash drive.

    Note! Remember, after formatting, all data, folders and files stored on the flash memory will be deleted.

    The procedure is as follows. Right-click on the drive and select “format”.

    Before us is a menu with settings.

    1. Flash drive capacity;
    2. File system;
    3. Volume label (drive name);
    4. Formatting method;
    5. Start the process.

    The main focus is on the file system. FAT 32 should be selected by default. This way, the contents of the drive can be “read” by any PC. You can give any name, since it does not affect any parameter.

    But for better formatting, it’s better to uncheck the “quick cleaning” box. Click “start” and wait.

    Folder Settings

    This technique is good for network directories. In other words, several PCs are combined into a single subnet. The administrator creates one or more public folders where various information can be dumped. To prevent anyone from accidentally deleting it, it sets access rights.

    This is done as follows. First, open the folder properties with the right button.

    Go to the “security” section and click “advanced”.

    We select a group or user whose rights we are cutting.

    We select the group again, and now we configure the access level.

    If you check the two boxes related to deletion, a user over the network will not be able to delete either the folder or its contents.

    After this, you can easily get rid of the application, since we “killed” it.

    In this simple way, you can clean your system of other programs, applications and folders.

    It’s impossible to say that this method is designed for the lazy. In any case, you will need to know the location where the folder is stored. On the other hand, all programs are initially installed in the Programm Files folder.

    How to delete a folder that is not deleted from the desktop and other places on the PC? By following our advice, you can easily get rid of various software that is stored in directories. The latter, in turn, can be easily and naturally eliminated.

    Important! The system will never complain if the list of files in the folder are not used anywhere at a given time. Whether it's a set of photos, movies or music. If you do not use the file, but for some inexplicable reason you cannot clean your computer, then the contents of the directory are simply infected with a virus. Just in case, scan your system for unwanted software and be careful when downloading something from the Internet.

    In all other cases, the culprit is simple negligence and unwillingness to read the message in the dialog box, which clearly explains the reason for the impossibility of deleting the folder.

    To enable data cataloging in Windows, as well as in other operating systems, a tree structure is used, which is a set of nested special file container objects called folders. In Windows, folders can be system folders, storing files of the operating system itself, or they can be user-defined or program folders, that is, those created by third-party applications.

    As a rule, the user can do whatever he wants with folders of the second type; he also has a lot of powers when working with program directories, for example, he can manually delete the folder remaining on the disk after uninstalling the application, but there are cases when the folder cannot be deleted by normal way. There may be several reasons for this. Most often this happens because the user does not have the necessary access rights; the directory may also be held by some process, may have an incorrect name, the path is too long, etc.

    Folder is not deleted due to lack of administrator permission

    Let's look at how to delete a folder if the action asks for permission from the administrator. This problem is most often encountered by users working under a regular or guest account, but this is also possible when you yourself are the computer administrator.

    In the first case, to delete a folder, you will have to enter the password for the PC owner’s account, since the system will constantly ask you for it, or use the universal method, which will be discussed at the end of the article.

    But what should you do if the folder is not deleted when working under an administrator account?

    The reason may be that you either do not own it or do not have the appropriate access rights. Open the folder properties, switch to the “Security” tab and click the “Advanced” button in the window that opens.

    In the new window, opposite the “Owner” line, click on the “Change” link.

    In the next window, click the “Advanced” button. Another window will open.

    Leave the object type in it as “User”, then click the “Search” button and select the user you want to make the directory owner from the list that appears at the bottom.

    Click "OK" and "OK" again.

    After the owner has been replaced, check the box next to “Replace owner of subcontainers and objects” and save the settings.

    Next, you will need to give the new owner full permissions to the folder. Click “Edit” in the properties window, select the desired user in the permission changes window, grant him full access rights and save the settings.

    After this, the folder should be easily deleted.

    Note: Folders owned by the system service are deleted in the same way. First, the owner of the folder is replaced, then he is granted (if necessary) full rights and the folder is deleted.

    The folder is being used by another program

    Like any other file system object, a directory may not be deleted because it is being used by some process. How to delete a folder in this case? The first thing you need to try to do is identify the process that is holding it, the second thing is to forcefully terminate it using Task Manager or another specialized utility. In most of these cases, when the folder is not deleted, Windows writes that it is being used by another program, and the name of this program is usually indicated in the message box.

    But it may also be that the program name will not appear. In such a situation, the utility can be a great help Process Explorer, included with the Sysinternals administration tools. Run the utility (it's portable), select from the main menu Find – Find Handle or DLL.

    Enter the name of the folder to be held in the “Handle or DLL substring” field and click “Search”. In a couple of seconds you will get the name of the process, its PID in the Task Manager and the full path to the object used by the process.

    By the way, using the utility, you can end the process and then delete the folder itself.

    The system says that it could not find this element

    Among the “undeletable” folders there is a special group that belongs to the so-called ghost objects. The difficulty here lies in the fact that it is not always possible to identify the reason for the appearance of such an object. This could be an incorrect (long or reserved) name, the action of a malicious program, another process blocking it, or damage to the file system. We already know how to check whether a process is blocking, now let’s try to figure out what to do if the folder is not deleted from the desktop with the message “this item could not be found.”

    If the folder has a system reserved name, such as COM or PRN, you can delete it using the command line. Launch the CMD console as an administrator and run the following command in it:

    rd //./Disk:/full path to the folder

    To delete a “non-deletable” folder with a too long name, you first need to know its short alias name. This is done again using the command line. Team cd /d (path) go to the parent directory of the problematic directory and print out the names of all the objects it contains using the command dir/x/n.

    Note: if the folder is on drive C, the key /d does not need to be used in a jump command.

    In our example, a folder with a name consisting of many dots has a short name 782F~1. Knowing the alias, we can safely delete it:

    rd C:/Users/compik/Desktop/782F~1

    A case that deserves special attention is when a folder is not deleted not because it has the wrong name or is being held by a system process, but because it simply does not exist, which may be indicated by the absence of an object in the command line list or the LiveCD file manager. This may indicate damage to the file system, therefore, before taking any further action, the disk must be checked for errors with the command CHKDSK.

    Action of viruses

    Less likely, but viruses that have entered the system can create a similar problem. Their action may be indicated by the constant automatic re-creation of the folder after its deletion using LiveCD or special utilities, as well as the presence of suspicious hidden files, executable or configuration, in the folder itself. The solution to the problem in such cases is standard - a full scan of the computer with at least two anti-virus scanners, preferably carried out in offline mode before loading the operating system.

    Invalid attributes

    Another possible reason why a folder is not deleted is that the system and read-only attributes are set for it. It’s easy to check the presence of such “holding” attributes; just run the command attrib [full path to the folder] in the command line. The presence of the S or R keys will indicate that the folder is read-only or system. To unlock a directory, run the following command in a command prompt running as administrator:

    attrib -r -s D:/Private /d /s

    In this example, we removed the “Read Only” and “Hidden” attributes for the Private directory at the root of drive D. After changing the attributes, the folder can be deleted.

    If the folder is not deleted from the desktop or any other location, you can try using the free Unlocker utility. This lightweight and extremely easy-to-use tool allows you to remove files and folders locked by system and third-party processes, it can also be useful when deleting objects that require higher access rights than local administrator rights, problems sharing files and folders, and other errors .

    How to delete a folder in Windows 7/10 using Unlocker? Very simple. During the installation process, the utility is built into the Explorer context menu, so to delete an object you just need to right-click on it and select the “Unlocker” option in the menu. If the object is not deleted immediately, a window will appear in which you can select the desired action, such as deleting, renaming and moving. If a file or folder is locked by a system process that cannot be closed immediately, the utility will offer to delete the object when the computer restarts.

    Above, we figured out why a folder may not be deleted from the computer, and at the same time we looked at the main ways to solve the problem. In conclusion, we suggest considering another way to delete blocked folders. Its main advantage is its versatility, since it allows you to gain almost unlimited access to the computer’s file system. For this you will need any LiveCD based on Linux or WinPE with a built-in file manager. Having set the appropriate priorities in the BIOS, boot from such a disk, use the built-in Explorer to find the blocked object and delete it.

    Often, when you try to delete a file, the operating system reports that it cannot be deleted because it is open in another program. Usually this problem is not serious and is very easy to solve. In this article we will look at three ways to delete a file if it is open in another program.

    Close the program that is blocking file deletion

    If you cannot delete a file because it is open in another program, then you should start by finding the very program that is blocking the file. Inspect the taskbar and system tray, then close all programs that may be related to this file.

    Pay special attention to programs that may have used this file in the past. For example, if a file was downloaded from the Internet, its deletion may be blocked by a download manager or torrent client.

    If a file was infected with a virus, the antivirus could quarantine it and block any actions with this file. In this case, it is better not to close the antivirus; instead, try deleting the file using the antivirus.

    Restart your computer or boot into safe mode

    If you have closed all programs, but the file is still not deleted, then you should try restarting your computer. Perhaps some program is stuck in the background and continues to block the file.

    In most cases, after a reboot, the programs begin to work normally, the file lock is removed and it can be deleted again. As a last resort, you can try booting your computer in safe mode. This will significantly increase the chances of successful file deletion.

    Use a program to unlock files

    If nothing helps and the file is still not deleted, then you can try to unlock it using special programs. One of the most famous and popular programs of this kind is the free Unlocker program. You can download this program from the official website of the developer.

    After installing the program, you need to right-click on the file that is not being deleted and select “Unlocker”.

    As a result, a window will open showing which program the file is open in.

    Select this program, click on the “Unblock” button and check whether the file is deleted.

    If the computer reports that the file is open in another program

    Most often, the inability to delete a file in Windows is due to the fact that it is occupied by some kind of system process. At the same time, the message “The action cannot be performed because this file is open in “” appears. The name of the program».

    In this case, you need to close the program that is using the file and try deleting again. If you see her window, just close it. If a program is running in the background and you don’t know how to close it, launch “Task Manager” (Ctrl + Alt + Del), find this program by name in the list, right-click on it and select “End task”.

    If you can't find the program you need in Task Manager, try a third-party utility that removes file locks. The free LockHunter app is suitable. After installing it, right-click on the file and select What is locking this file?. When the LockHunter window appears, click on the Unlock It! button in it.

    After that, try deleting the file again. If unsuccessful, restart your computer and try again. To completely remove it from your computer, be sure to empty the Recycle Bin.

    If your computer says you are denied access

    Sometimes you cannot delete a file because your account does not have rights to do this. In such cases, Windows reports that access is denied. To resolve this issue, you need to change the owner of the file. During the process, you may need the login and password for your PC administrator account.

    To change access rights, right-click on the file and go to “Properties” → “Security” → “Advanced”. Near the “Owner” item, click “Edit”, then “Advanced” and “Search”. Select your current account from the list and click OK.

    After doing this, you will most likely be able to delete the file as usual. If it doesn't work, try restarting your computer and trying again.

    How to delete a file on macOS

    If the Mac says the file is in use

    First, manually close the applications in which you used this file and try to erase it again. They can interfere with uninstallation, as happens in Windows. If unsuccessful, restart your computer and repeat the removal.

    If it doesn't work, enter safe mode. To do this, restart your Mac while holding down the Shift key. Try moving the file to the Recycle Bin and emptying it, then restart your computer as normal.

    If the file cannot be deleted for other reasons

    The file may not be deleted due to disk errors. Therefore, launch “Disk Utility” in the Finder → “Programs” → “Utilities” section and check the disk on which the file is located using the “First Aid” service.

    After checking, restart your Mac and try deleting the file.