EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Strange behavior in CloseFileN

Also by EldoS: RawDisk
Access locked and protected files in Windows, read and write disks and partitions and more.
#33700
Posted: 06/18/2015 07:49:50
by Massimiliano Saponaro (Basic support level)
Joined: 06/18/2015
Posts: 3

Hi all.
I'm trying to understand CBFilter_VS2010 sample.
I want to show a message box every time a user close a file in a specific folder.

I have modified this method:
public void CbFltCloseFileN(
object Sender,
string FileName
)
{
MessageBox.Show(FileName);
}

and I configure the interface in this way:

Mask:
C:\Users\Massimiliano\Desktop\FSW\cbflt_eval\*.*
and SetCloseNotify in the drop down list.

I see more and more message box when I close a file but also when a click or open a file.
What's wrong?

Thanks!
#33705
Posted: 06/18/2015 09:47:59
by Eugene Mayevski (EldoS Corp.)

Explorer opens and closes files of the directory to which you navigate. Most likely you are seeing exactly this.

On a side note it would help a lot if you used CODE button (or write [ CODE ] and [ /CODE ] respectively by hand) to mark the beginning and the end of the code blocks in your messages. This would enable syntax highlighting and line numbering on the code and make it easier for analysis.


Sincerely yours
Eugene Mayevski
#33745
Posted: 06/23/2015 11:24:33
by Massimiliano Saponaro (Basic support level)
Joined: 06/18/2015
Posts: 3

Hi again.
I'm using FileMonitor sample...

I try to open e then close a txt file.
In the first screen shot, there are the events fired on opening file and as you can see there are a lot of open and close event.
Idem when I try to close the file.

In the log procedure I exclude these process:
explorer.exe
tsvncache.exe
host.exe

How can I understand when a file is open and the same file is closed?

Thanks in advance!



Reply

Statistics

Topic viewed 2569 times

Number of guests: 1, registered members: 0, in total hidden: 0




|

Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!