Prev: OpenEvent() fails on Vista for some processes while trying toopen global event
Next: OpenEvent() fails on Vista for some processes while trying toopen global event
From: Alin on 16 Dec 2009 07:04 Hi there My application has to work with a 3rd party control that opens a file. All works ok except that it seems that under vista and windows 7 the file remains locked after the the form containing the control is unloaded and the only way to unlock it is to close the whole application. So my guess is that the handle of the file is not released property but I don't have access to the code of the control. So here is my question: is there a way to find the "lost" handle knowing the file path? I could try to close it by my own but first i need the handle itself. The project is old and written in vb6, but also c++ code is fine. Thank you in advance.
From: David Lowndes on 16 Dec 2009 10:41
>My application has to work with a 3rd party control that opens a file. >All works ok except that it seems that under vista and windows 7 the >file remains locked after the the form containing the control is >unloaded and the only way to unlock it is to close the whole >application. So my guess is that the handle of the file is not >released property but I don't have access to the code of the control. First of all, ensure that this is the issue - use the SysInternals Process Explorer tool to find any handles referencing your file. If the problem doesn't exist under XP I think you need to discover why - as far as I know there shouldn't be any difference in that respect. Dave |