log4net SDK Reference |

# AppenderSkeleton.RenderLoggingEvent Method (LoggingEvent)

Renders the LoggingEvent to a string.

[Visual Basic]
Overloads Protected Function RenderLoggingEvent( _
ByVal loggingEvent As LoggingEvent _
) As String
[C#]
protected string RenderLoggingEvent(
LoggingEvent loggingEvent
);

#### Parameters

loggingEvent
  The event to render.

#### Return Value

The event rendered as a string.

#### Remarks

Helper method to render a LoggingEvent to a string. This appender must have a Layout set to render the loggingEvent to a string.

If there is exception data in the logging event and the layout does not process the exception, this method will append the exception text to the rendered string.

Where possible use the alternative version of this method RenderLoggingEvent. That method streams the rendering onto an existing Writer which can give better performance if the caller already has a TextWriter open and ready for writing.

#### See Also

AppenderSkeleton Class | log4net.Appender Namespace | AppenderSkeleton.RenderLoggingEvent Overload List