Set the ErrorInfo.LogToFile property to true to record time-stamped error codes to a file. Most UL for .NET method returns either an ErrorInfo object or 0. If an error occurs, an ErrorInfo object is returned.
Member of the ErrorInfo class.
VB .NET
Public Property LogToFile As Boolean
C# .NET
public bool LogToFile [get, set]