Re: Is file is being used



What I find to be amazing is that this thread exists in 2006.

A system on which I was programming in 1976 that only had 16K of RAM and supported up to 16 attached (via coax) workstations supported the concept of "Open Private". Stated simply, if a file was already open, even if the other workstation had done an "Open Shared", my open would fail. The unit that functioned as the "cluster controller" took care of this for me. File and record locks were forced, not cooperative.

By the way, the system was a Singer/ICL 1500 series manufactured in Utica, NY. It saw a lot of use in the retail market as it also was capable of supporting electronic cash registers (POS devices).

Mike
..

Rad [Visual C# MVP] wrote:
On 12 Dec 2006 06:03:04 -0800, Eran.Yasso@xxxxxxxxx wrote:

Hi,

I have a mdb file shared in the LAN. I want to write app that verifies
if it's open.
If the file is not open, then my app can open the file.
if the file is used, then the app won't open it.

I also want this app to have handle to this file, then when the user
stops editting this file, he can close it using this app.

so my questions are:

1. How can i tell if a file is being used(edited, open, etc'...)
2. How can i close file(and save the data)?

TIA.

If I'm not wrong a MDB generates a temporary lock file when it is open,
with the same name but the extension .LDB. You can try checking for the
existence of that file to know if its is open

As for closing it from another application -- not sure about that
.



Relevant Pages

  • Re: Good Reasons to port asp.NET VB.NET app to C#
    ... I think you'll find that migrating the pages from VB.NET to C# is trivial and shouldn't take you much time at all. ... Now they want to add new features change some of the existing ones, it's not a major rework, but probably a week of work or so. ... Now would be a good time to port this app to C# with new features which will add probably twice as much time to development of this new release. ... If I am going to be supporting this app I want to support in C#. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Good Reasons to port asp.NET VB.NET app to C#
    ... Now they want to add new features change some of the ... > time to rewrite this application to C#. ... If I am going to be supporting this app I want to support in C#. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Using VS.NET 2005 to support VS.NET 2003 app
    ... >> provide me with an MSDN subcription, so what I am wondering is, do I need ... > I managed to fix that, but, if loading a VB.NET 2003 app into 2005 causes ... > But, back to your quesiton, since the app you are going to be supporting ... Both are tied to their individual frameworks. ...
    (microsoft.public.vsnet.general)
  • Re: Using VS.NET 2005 to support VS.NET 2003 app
    ... settings in the Forms Designer that is set at Design Time raise an error in the Import and say that those settings are ... I managed to fix that, but, if loading a VB.NET 2003 app into 2005 causes problems and the Import function cannot fix them, then ... But, back to your quesiton, since the app you are going to be supporting is written with VS.NET 2003 and version 1.1 of the ...
    (microsoft.public.vsnet.general)
  • Re: Whose Fish?
    ... That would be much more in line with your Table Oriented Programming ... cart structure/object floating around in the app. ... intuitive way, as it is with a good object model, ... I might load CustomerInfo with read only ID ...
    (comp.object)