[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

OpenEventLog /RegisterEventSource

Posted on 2001-07-21
2
Medium Priority
?
1,318 Views
Last Modified: 2008-01-09
Hi Folks,

what's the difference between these two functions?
OpenEventLog()/RegisterEventSource() - they both require the same arguments, return the same info, seem to be used for the same purpose.

when should i use one and not the other?

thanks and regards,

Mike.

0
Comment
Question by:meverest
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 86

Accepted Solution

by:
jkr earned 200 total points
ID: 6305138
>>when should i use one and not the other?

They both serve different purposes - 'RegisterEventSource()' is used when reporting an event:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/debug/hh/winbase/eventlog_969g.asp

"After you have added a source name to the registry, use the RegisterEventSource function to get a handle to the Application event log. The following example obtains the handle and then adds an event to the log using the ReportEvent function."

Whereas 'OpenEventLog()' is used for reading the event log:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/debug/hh/winbase/eventlog_2u93.asp
0
 
LVL 37

Author Comment

by:meverest
ID: 6305471
ok,

that seems sensible enough.  if only the devstudio online docs made it that clear! ;-)

thanks and regards.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question