Return Value

The event source indicates what logs the event. It is often the name of the application, or the name of a subcomponent of the application, if the application is large. Applications and services should write to the Application log or a custom log. Device drivers should write to the System log.

When you create a new source, which can only write to one log at a time, the system registers your application with the event log as a valid source of entries. The Source property can be any string, but the name cannot be used by other sources on the computer. An attempt to create a duplicated Source value throws an exception. However, a single event log can have many different sources writing to it.