XdsObjects Help file
XdsObjects Namespace / XdsGlobal Class / LogToFile Method / LogToFile(String,LogLevel,Int32) Method

Path as string :

The location of the log files.

If an empty string being passed, XdsObjects will use the user's documents directory as the default location.

But still it is the caller's responsibility to ensure either that the path is valid and correct.

LogLevel as Integer:

This value controls the level of details logged to the file.

The time interval in Minutes when a new log file should be generated.



LogToFile(String,LogLevel,Int32) Method
Enables XdsObjects logging, specifies where XdsObjects log files appear, what the logging level is and the timer interval when new log file should be generated.
Syntax
Public Overloads Shared Sub LogToFile( _
   ByVal Path As String, _
   ByVal Level As LogLevel, _
   ByVal RestartInterval As Integer _
) 
Dim Path As String
Dim Level As LogLevel
Dim RestartInterval As Integer
 
XdsGlobal.LogToFile(Path, Level, RestartInterval)
public static void LogToFile( 
   string Path,
   LogLevel Level,
   int RestartInterval
)
public:
static void LogToFile( 
   String^ Path,
   LogLevel Level,
   int RestartInterval
) 

Parameters

Path

Path as string :

The location of the log files.

If an empty string being passed, XdsObjects will use the user's documents directory as the default location.

But still it is the caller's responsibility to ensure either that the path is valid and correct.

Level

LogLevel as Integer:

This value controls the level of details logged to the file.

RestartInterval
The time interval in Minutes when a new log file should be generated.
Remarks

The RestartInterval parameter provides a means to restart the logging on a regular time basic. This is useful to avoid log file end up being HUGE.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also