This topic has not yet been rated - Rate this topic

EventSource.WriteEvent Method

.NET Framework 4.5

Writes an event by using the provided event identifier and optional arguments.

This member is overloaded. For complete information about this member, including syntax, usage, and examples, click a name in the overload list.

  Name Description
Protected method WriteEvent(Int32) Writes an event by using the provided event identifier.
Protected method WriteEvent(Int32, Int32) Writes an event by using the provided event identifier and 32-bit integer argument.
Protected method WriteEvent(Int32, Int64) Writes an event by using the provided event identifier and 64-bit integer argument.
Protected method WriteEvent(Int32, Object[]) Writes an event by using the provided event identifier and array of arguments.
Protected method WriteEvent(Int32, String) Writes an event by using the provided event identifier and string argument.
Protected method WriteEvent(Int32, Int32, Int32) Writes an event by using the provided event identifier and 32-bit integer arguments.
Protected method WriteEvent(Int32, Int64, Int64) Writes an event by using the provided event identifier and 64-bit arguments.
Protected method WriteEvent(Int32, String, Int32) Writes an event by using the provided event identifier and arguments.
Protected method WriteEvent(Int32, String, Int64) Writes an event by using the provided event identifier and arguments.
Protected method WriteEvent(Int32, String, String) Writes an event by using the provided event identifier and string arguments.
Protected method WriteEvent(Int32, Int32, Int32, Int32) Writes an event by using the provided event identifier and 32-bit integer arguments.
Protected method WriteEvent(Int32, Int64, Int64, Int64) Writes an event by using the provided event identifier and 64-bit arguments.
Protected method WriteEvent(Int32, String, Int32, Int32) Writes an event by using the provided event identifier and arguments.
Protected method WriteEvent(Int32, String, String, String) Writes an event by using the provided event identifier and string arguments.
Top

The WriteEvent method provides overloads with combinations of string and integer arguments. If none of these combinations match the parameters for the call, the compiler uses the EventSource.WriteEvent(Int32, Object[]) overload, which is considerably slower than the other overloads. See the overload page for details.

You can also create a custom overload by using the WriteEventCore method.

Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.