More Custom install action does not register event log sources

  • Thread starter Alhambra Eidos Kiquenet
  • Start date
A

Alhambra Eidos Kiquenet

Actually, my installer package is not for a Windows Service, but for a
WinForms application.
Well, it is kind of both: this is a multi-project solution with its main
target being a WinForms application, but it also includes a Windows Service.

My custom install actions configuration includes output from a Class Library
project that contains the custom actions followed by the output of the
Windows Service project to register the service.
The custom install actions DLL creates the custom event log and registers
several sources, one of them being the source used by the Windows service.

After the install has completed I go to
HKLM\System\CurrentControlSet\Services\EventLog\<My Custom Log> to check
which sources have been registered for that log and the only source that is
registered is the name of the log itself. I examined the installation log
file and wasn't able to find any reference to the custom event sources that
were supposed to be registered, like it never happened.

However, if I execute my custom install action DLL using the InstallUtil.exe
I can clearly see in the installation log file that all my custom event log
sources are being registered and they appear in the abovementioned registry
location as expected.

To verify that the EventLogInstaller instances are being called during the
installation I have created a subclass of the EventLogInstaller and
overridden its Install/Commit/Uninstall events to display a message box. I
can see the message box appear on the screen for each of the custom sources
during the installation, which tells me that the EventLogInstaller is being
executed.

The question is - why doesn't it register any of the event log sources?

Regards, thanks in advance !!!
 
A

Alberto Poblacion

Alhambra Eidos Kiquenet said:
[...]
The question is - why doesn't it register any of the event log sources?

¿Could it be a credentials issue? The code needs to be running as
Administrator in order to register the event log source.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top