By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,628 Members | 1,175 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,628 IT Pros & Developers. It's quick & easy.

intercept "Open" event for any files in a given folder

P: n/a
Hi all
Is it possible for a .Net app. to intercept the "open" action on files in a
given directory.
I want to intercept the "open" action and the perhaps direct the client (
the app. which is trying to open the file ) to another file - or stream
another file back to the client in someway???

Any help is appreciated

Regards Morten
Jul 21 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hello Morten,

Thanks for your post. As I understand, you need to intercept the "open"
file action and redirect to open another file. Please correct me if there
is any misunderstanding. I now share the following information with you:

1. In .NET, we can use the FileSystemWatcher class to listen to the file
system change notifications and raises events when a directory, or file in
a directory, changes. With this class, we can watch for renaming, deletion,
or creation of files or directories. Please refer to the following MSDN
documentation:

FileSystemWatcher Class
http://msdn.microsoft.com/library/de...us/cpref/html/
frlrfsystemiofilesystemwatcherclasstopic.asp

2. Please kindly note that FileSystemWatcher is just used to get
notifications of file/directory changes. If you want to intercept the file
manipulations and change their behavior, you may need to resort to API Hook
or even File System Filter Driver. Please take a look at following articles:

API Hook SDK
http://www.apihook.com/apihook/index.shtml

Installable File System (IFS) Kit
http://www.microsoft.com/whdc/ddk/ifskit/default.mspx

Hope this helps.

Regards,

HuangTM
Microsoft Online Partner Support
MCSE/MCSD

Get Secure! -- www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Jul 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.