How can I release locks on files once they are closed

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
User avatar
vimil
Posts: 7
Joined: Mon Mar 26, 2007 5:40 pm
Location: seattle wa

How can I release locks on files once they are closed

Post by vimil »

Textpad 5.2.0 does not release locks on files once they are closed on WindowsXP.

Try opening a file in textpad and close teh file. Then try to delete the file. Windows throws an error sayng the file is in use by a program or person. Howeevr once textpad is closed teh file can be deleted.
nvj1662
Posts: 56
Joined: Thu May 17, 2007 10:02 am

Post by nvj1662 »

I just tried that with Textpad 5.20 on Windows XP SP2 and the file deleted OK. It works fine for me :)
User avatar
vimil
Posts: 7
Joined: Mon Mar 26, 2007 5:40 pm
Location: seattle wa

these are the steps I followed

Post by vimil »

1) Created a folder called 'test' on C drive
2) created a text file called test.txt on C:\test
3) opened test.txt in textpad and modified the file.
4) saved and closed test.txt from textpad (textpad is still open)
5) tried to delete the folder test.

Windows says the folder cannot be deleted as it is in use by another person or program.

I first thought it was the file that was being locked but I was able to delete test.txt. It is the folder that I cannot delete. It seems textpad has lock on the folder the file is present in.

Could you try if the samething happens to you too?
It cant be just me :o
ak47wong
Posts: 703
Joined: Tue Aug 12, 2003 9:37 am
Location: Sydney, Australia

Post by ak47wong »

You're right, TextPad has a lock on the folder because it is the working folder. If you want to delete the folder, open a file in another folder first.

Andrew
ben_josephs
Posts: 2459
Joined: Sun Mar 02, 2003 9:22 pm

Post by ben_josephs »

Or deselect
Configure | Preferences | General | Working folder follows active document
if you're prepared to do without it.
User avatar
vimil
Posts: 7
Joined: Mon Mar 26, 2007 5:40 pm
Location: seattle wa

Post by vimil »

Unchecking the 'working folder follows active document' works, but I really like that feature.

I mostly use textpad to track log files. I have log files located at different folders and the 'working folder follows active document' feature saves me a lot of mouse clicks to open another file from a folder that has already a file open.

Is there any reason why textpad has to lock a folder, if it has no open files in that folder?
nvj1662
Posts: 56
Joined: Thu May 17, 2007 10:02 am

Post by nvj1662 »

Just to be clear on my last, I do have "Working folder follows active document" un-ticked. Following your instructions to the letter, I was able to delete the folder OK. Windows just asked for confirmation that I wished to delete the folder to the recycle bin, then did so without further comment.
User avatar
vimil
Posts: 7
Joined: Mon Mar 26, 2007 5:40 pm
Location: seattle wa

Post by vimil »

It works fine when the 'working folder follows current document' is un-ticked. But I need that option enabled. Its comes very handy when trying to open other files from a folder that has already a file open in textpad.
nvj1662
Posts: 56
Joined: Thu May 17, 2007 10:02 am

Post by nvj1662 »

You might like to try this www.filehippo.com/download_unlocker/. I have not yet tried it but it claims to unlock file-locked windows files so should work on directories too.
OppfinnarJocke
Posts: 7
Joined: Wed Sep 03, 2008 9:34 am

Issue with USB

Post by OppfinnarJocke »

Open a file from an USB-drive
Save the file as a new file on another HD
Try to safely remove the USB-drive

The USB-drive is now locked by Textpad 5.2 even though it has no file open on the drive. Even closing the file (now saved under another name on another drive) does not help. Closing Textpad allows the USB-drive to be safely removed.
magus424
Posts: 4
Joined: Tue Apr 21, 2009 8:36 pm

Post by magus424 »

If you open a file in another directory it will shift the working dir and allow the folder to be removed.
Post Reply