Locked Files Wizard

Version 2.4 (May 2010)
© 2001-2010, Noël DANJOU
All rights reserved.


Welcome

The Locked Files Wizard, formerly known as CopyLock, is an assistant that allows you to either delete, move or rename files or folders used by the system or any other application or process. You can display and possibly stop the processes or services that use executables, folders or dynamic-link libraries (DLL) and try the operation again to possibly avoid restarting your system and thus save time.

The wizard also allows you to quickly pick the image path of a process (Select > File from Process) or a program that runs at startup from the Registry (Select > File from Registry), to manage it. This may be useful to quickly remove worms, trojans or any other malware from a system.

Additionally you can manage the pending operations that are delayed until the next reboot.

The package includes a command-line version that can be used from a Command window or a script.

Note: this version is Unicode only that means that it will only run in Windows 2000 and later. Windows 98 and ME are not supported anymore.

Disclaimer: you can possibly crash your system or prevent an installed program from working if you are not careful, use at your own risk.

 

Table of Contents
Welcome
Package Content
Features
Limitations
Syntax
Return Codes (ERRORLEVEL)
History
Latest Version
Registration
Redistribution
Contact Details

Package Content

The package is provided as a compressed (zip) archive that holds a few files. The included files are described in the table below.

File Description
lfcmd32.exe Locked Files Command (32-bit version).
lfcmd64.exe Locked Files Command (64-bit version).
lfwiz32.exe Locked Files Wizard (32-bit version).
lfwiz64.exe Locked Files Wizard (64-bit version).
readme.htm This file.

Note: this package does not include an installer so that you can easily move or delete the files. However if you clicked the Install button from the wizard, the shell command won't work anymore if you move the wizard executable to another place. You can click the Install button again to update the command. If you already installed the command and you plan to permanently delete the application, click the Uninstall button before deleting the executable.


Features

The Locked Files Wizard allows you to complete many tasks, some of them are listed below. Even though the program is designed to allow files in use (aka "locked files") to be deleted or renamed/moved on the next reboot, its primary goal is to identify the processes that use the files and to allow you to stop these processes and to manage the files without restarting your system.

Note: if a file cannot be selected using Select... > File because the system reports that the file name is reserved for use by Windows, close the Open dialog box and type the full path yourself (possibly using the auto-complete feature).


Limitations


Syntax

The Locked Files Command, the command-line counterpart of the Locked Files Wizard, features many parameters; for a whole list of the supported parameters and a description, type the following command in a Command window:

lfcmd32 /?

The source and target paths are optional if the /pending parameter is specified otherwise at least the source path is required. If a source path is specified but neither a target path nor one of the following parameters: /close, /info or /process are specified then the source file or folder will be deleted instead of being moved or renamed.

Note: The Locked Files Command must be run from a Command window with Administrator rights if you encounter Access Denied errors.


Return Codes (ERRORLEVEL)

When the Locked File Command is used in a batch file, you can use ERRORLEVEL to check the completion code returned by the program. The possible return codes are listed in the table below. Please note that the wizard always returns 0 since it is not intented to run from a batch file.

Code Description
0 Success.
1 Syntax error, invalid URL or help/registration information displayed.
2 System error (e.g. out-of-memory).
3 Pending operations could not be retrieved from the Registry.
4 Unsupported operation.
5 File downgrade not allowed. (see /downgrade)
6 System-protected file operation not allowed. (see /protected)
7 Operation failed.
8 Reboot failed. Some pending operations are queued.

History

May 5, 2010 - Version 2.4 (Build 40.3)

  • Adds tooltips to the wizard-specific buttons.
  • Adds auto-complete to the pages where a path is expected.
  • Adds a Select > File From Process option to the Select a file or folder page to quickly pick an image path from a process in memory.
  • Provides both 32-bit and 64-bit versions of the program to support both x86 and x64 systems.
  • Improves high-DPI support.
  • Fixes an issue regarding recursive folder enumeration in case of folder deletion.
  • Fixes Registry updates when a file is moved or renamed (possible parameters were not restored).
  • Locked Files Command mostly rewritten, adds new parameters (see lfcmd32 /?).
  • Some user interface improvements and bug fixes.
  • First Unicode release, the program is no more supported on older Win9x/ME systems.

May 7, 2007 - Version 2.3 (Build 24.1)

  • Removes some unexpected debug messages related to drag-n-drop support.

April 26, 2007 - Version 2.3 (Build 23.4)

  • Renames both executables to lfwiz.exe (Wizard) and lfcmd.exe (Command Line) respectively.
  • Adds a digital signature to both executables.
  • Adds UAC support for Windows Vista.
  • Data are now appended in the log files instead of overwritten.
  • The command-line version now reports error to the log file as well.
  • Allows the wizard tp reach the Completion page even in case of error so that a log file can be generated. Use Back button to make a new attempt.
  • Updates wizard font.

April 14, 2006 - Version 2.2 (Build 18.5)

  • Process enumeration code rewritten from scratch so that it works on Windows 9x/ME systems.
  • Services are now identified as such and gracefully stopped when End Process is clicked.
  • Adds infotips for every listed process.
  • Renames the Register button to Install to avoid confusion with the Register button to buy the program online.

February 27, 2006 - Version 2.1 (Build 15.1)

  • Adds the Register link in the About box.
  • Adds some minor updates.

December 21, 2005 - Version 2.1 (Build 11.3)

  • Fixes the formatting of the error message that appears when an item cannot be added, which could possibly lead to a crash.

October 28, 2005 - Version 2.1 (Build 10.5)

  • Adds the possibility to select a file from the Registry so that both a file and associated key are deleted all at once. This can help to quickly remove some worms or trojans from a system (this won't replace an antivirus program though).

April 27, 2005 - Version 2.0 (Build 9.3)

  • Enhances drag-n-drop support for special folders.
  • Now reports the actual error message when one or more items cannot be added instead of "out of memory".

April 8, 2005 - Version 2.0 (Build 7.5)

  • Renames executable to lfw.exe.
  • Fixes a few layout issues.
  • Updates shared code with the command-line version.
  • First release of command-line version (build 1.0.3.5).

April 5, 2005 - Version 2.0 (Build 4.2)

  • First release.

Latest Version

The latest version of the Locked File Wizard is always available for download from this address:

http://noeld.com/programs.asp?cat=misc#CopyLock2


Registration

Even though this version of the program is fully functional, I beg you please to register to show your support and your interest. Your support would allow me to add more features and to possibly fix bugs.

To register, click the link just below and follow the instructions.

https://www.regnow.com/softsell/nph-softsell.cgi?item=4076-6

Alternatively, you can click the About button (on the first page of the assistant) then click the Register Now link.

Orders and delivery are handled by the Register Now company.


Redistribution

Computer magazine publishers are welcome to redistribute the application as-is on their complimentary or monthly CDs. Any other redistribution of the application with commercial products is strictly forbidden without my written permission. Please contact me for a license agreement (see Contact Details).


Contact Details

E-mail: webmaster@noeld.com

WWW: http://noeld.com/