Logger.Write Method (Object)

Retired Content

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

The latest Enterprise Library information can be found at the Enterprise Library site.

Write a new log entry to the default category.

Namespace:  Microsoft.Practices.EnterpriseLibrary.Logging
Assembly:  Microsoft.Practices.EnterpriseLibrary.Logging (in Microsoft.Practices.EnterpriseLibrary.Logging.dll)

public static void Write(
	Object message


Type: System.Object
Message body to log. Value from ToString() method from message object.

The following example demonstrates use of the Write method with one required parameter, message.
Logger.Write("My message body");