hello,
I wanted to know how can know when one file is accessing another file and
modifying it. I need to know which file modified which file.
how can I do that?
thanks
:wave:
Printable View
hello,
I wanted to know how can know when one file is accessing another file and
modifying it. I need to know which file modified which file.
how can I do that?
thanks
:wave:
Files don't access or modify other files, programs do.
ok, so how can I monitor these programs?
I don't believe you can. What is the problem you are trying to solve?
I know of a program -called Freefile- which can tell you which files are opened/locked and by which programs, so it can be monitored.
I assume that you would need to talk to the filesystem through some API and ask what is opened.
You might want to look at the DeviceIOControl Function
yes, microsoft word for example tells you what program has a locked a file it's trying to open.
That's because all MS Office applications create an information file whenever they put a lock an a document of some sort.Quote:
Originally Posted by dis1411
But a program is also a file :)Quote:
Originally Posted by MartinLiss
No, a program is not a file.
A program is a list of intructions to the computer so it can complete a task.
Saving this list to disk is useful if you want to use it again in the future but not mandatory.
Just open a new VB project and run it without saving.
And it is not the program's file that accesses things, it is the program loaded into memory that does.
If you compile it on demand, it will create a temp file.