Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6798123
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T18:41:31+00:00 2026-05-26T18:41:31+00:00

Is there an API to create a Custom View in Windows Event Viewer? I

  • 0

Is there an API to create a Custom View in Windows Event Viewer?

I would like to do that in the installation using NSIS,
But if I cant and there is any other way then I’ll write a plugin for it.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T18:41:32+00:00Added an answer on May 26, 2026 at 6:41 pm

    The problem is not NSIS but the way the Event Log works, you need to install a message table DLL somewhere on the system and register it in the registry. This DLL has to stay on the system since it is used by the Event Log Viewer when you view the log and is not used when you log the message! This design is really problematic for a installer.

    It is probably better to just log to a plain text file in $temp or $exedir.

    If you really want to use the Event Log and you don’t mind hacks you could:

    • Put the message table DLL in $pluginsdir and register/unregister when the installer starts/ends (If it crashes you leave junk in the registry!)
    • Use a Microsoft/Windows message table (They are not documented, could change from version to version (And service packs?) so you would have to test every Windows version and configuration you support!)

    The NSIS code looks something like this:

    section
    
    System::Call 'advapi32::RegisterEventSource(i0,t "Software Installation")i.r0'
    #TODO: Check if $0 == 0 and display error message
    System::Call '*(i,&t1000 "Hello world")i.r1'
    IntOp $2 $1 + 4
    System::Call '*$1(ir2)'
    System::Call 'advapi32::ReportEvent(ir0,i ${EVENTLOG_ERROR_TYPE},i0,i 101,i0,i1,i0,ir1,i0)i'
    System::Free $1
    System::Call 'advapi32::DeregisterEventSource(ir0)'
    
    sectionend
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using the automation API to create custom control patterns. Now that I've created
since Windows Vista there is an new Win32-API call CreateSymbolicLink to create a symbolic
Are there Windows API functions that allows reading what the current password policy is?
Is there an API function call for this board that would allow me to
Is there a way to create custom infowindow in new API V3 of googlemaps.
Is there a way to create an index and specify a custom analyzer using
Is there a way to create a custom attribute that will make EF CodeFirst
Is there any API SQL Server 2008 offers for .net application to create and
Is there an API call in .NET or a native DLL that I can
I wanted to create a custom combo box like this (as in MS Word),

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.