Re: ReportEvent and MessageDLL problem
- From: "Mark Yudkin" <myudkinATcompuserveDOTcom@xxxxxxxxx>
- Date: Wed, 22 Jun 2005 09:01:16 +0200
Correct. Your user doesn't have permission to create the registry entries
using his own account.
To work around this, you'll need to create a small advertised MSI
installation that the user can run (with elevated privileges). You can fire
up this installation using your program when the user needs to perform the
installation.
You may want to take this to an MSI forum, as it's not a VB6 issue.
"Sachin_M" <SachinM@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:CA1E4217-C998-4826-B770-ED8C4DB7661F@xxxxxxxxxxxxxxxx
> Thanks Mark,
>
> Well my application is an event logger. The user configures it with new
> event node before he executes it. And the code should take care of new
> event source creation/registration of the same if exists.
>
> You mean, under Windows XP, for normal user (i.e. other than Administrator
> login)
> this won't work at all?
> I mean, I can't create custom log at runtime for a normal user account?
> As I've not tested it on XP.
>
> Regards,
> Sachin M
>
>
>
> "Mark Yudkin" wrote:
>
>> Create a key for your application name (value of your strEventSource
>> variable) under
>>
>> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\Application\
>> Under that new key, create a REG_SZ value with the name EventMessageFile
>> and
>> value as the path to your DLL.
>> Also create a REG_DWORD value with the name TypesSupported and value 7.
>>
>> Since normal users on XP do not have write access to this part of the
>> registry, you need to do this in your installation program. Installation
>> programs are best written using MSI (not VB6) as MSI installations can be
>> run with the necessary elevated privileges.
>>
>> "Sachin_M" <SachinM@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> news:781CB3E6-FCB1-4931-BBC4-D986D94291A7@xxxxxxxxxxxxxxxx
>> > Hi Friends,
>> > I'm using following APIs to create custom event log in windows
>> > RegisterEventSource ("", strEventSource)
>> > ReportEvent (lngHwnd, LogType, 0&, EventID, 0&, 1, 0&, lngHwndMsg, 0&)
>> > and then
>> > DeRegisterEventSource (lngHwnd)
>> > Now, my application is designed to log events on regular intervals of 1
>> > second.
>> >
>> > The problem is I'm unable to use MessageDll which I've created with
>> > VC++
>> > 6.0
>> > and Message compiler (mc.exe)
>> > The same Messagedll i've used successfully in VC++ which avoids the
>> > windows
>> > header .....
>> > <Description:
>> > The description for Event ID ( 1001 ) in Source ( DLLtest ) cannot be
>> > found.
>> > The local computer may not have the necessary registry information or
>> > message
>> > DLL files to display messages from a remote computer. The following
>> > information is part of the event: My test message.>
>> >
>> > but its (messagedll) not working with VB.
>> > Can somebody please help me in this? I figure out that there is some
>> > prob
>> > in
>> > api calling from VB.
>> >
>> > And I need to use createRegistry and regSetValueEx to set
>> > eventMessageDLL
>> > path.
>> >
>> > How to do this?????
>> >
>> > Thanks & Regards,
>> > Sachin Malode
>> >
>> >
>>
>>
>>
.
- Follow-Ups:
- Re: ReportEvent and MessageDLL problem
- From: Sachin_M
- Re: ReportEvent and MessageDLL problem
- References:
- ReportEvent and MessageDLL problem
- From: Sachin_M
- Re: ReportEvent and MessageDLL problem
- From: Mark Yudkin
- Re: ReportEvent and MessageDLL problem
- From: Sachin_M
- ReportEvent and MessageDLL problem
- Prev by Date: Re: EnumWindows
- Next by Date: Re: VB 6 app crashes on windows 2003 server
- Previous by thread: Re: ReportEvent and MessageDLL problem
- Next by thread: Re: ReportEvent and MessageDLL problem
- Index(es):
Relevant Pages
|
Loading