How to edit a file in java

I want to write a java application. It works in the background, and when a user tries to open a file or directory (double-click or right-click and select "Open") in a specific folder, an event will be generated, and I can do something in the event handler. Can this be detected in java? Btw, it seems the java.nio package cannot detect this.

+5
source share
2 answers

You can view all files to see if they were locked in Windows.

It is impossible to determine whether a file is opened by the direct user or is simply scanned by another program, for example. search for words.

I suspect that everything you are trying to do is done better or more reliably in a different way.

+3
0

All Articles