Article View: borland.public.cppbuilder.nativeapi
Article #14794Detect file/document opening
From: Greg
Date: Sun, 03 Aug 2003 11:42
Date: Sun, 03 Aug 2003 11:42
26 lines
1589 bytes
1589 bytes
Hello,
how is it possible to detect using a hook or another way
to catch a file or document being opened.
I am using in my program dll a shellhook which is catching
and posting the program file names which have been launched.
if (nCode == HSHELL_WINDOWCREATED)
{
char buffer[256] = {0}; // room for extra null terminator
GetModuleFileName(0, buffer, sizeof(buffer));
......
I am interested to catch the parameter (f.e \windows\notepad.exe
parameter.txt).
If there is any non-hook way to check if a file is now opened I
would be happy to hear about it.
The aim is to monitor a list of files on their opening.
Thanks a lot,
Greg
Technical Details
Message-ID:
<3f2ce71f@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,a3b6002815786b16,start X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2003-08-03 03:54:03 PST From: "Greg" <gkoslov@gregsoft.co.il> Newsgroups: borland.public.cppbuilder.nativeapi Subject: Detect file/document opening Date: Sun, 3 Aug 2003 13:42:23 +0200 Lines: 28 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 NNTP-Posting-Host: 132.66.222.210 Message-ID: <3f2ce71f@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1059907359 132.66.222.210 (3 Aug 2003 03:42:39 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail