SLLogX is an ActiveX component that can be used to create and handle text log files. The log control can for example be used for storing real-time statistics or for locating errors in applications.
Before you can add any rows to a log file you must open it with the Open method. When you have finished adding data to the file you must close it with the Close method. All methods, except for GetLastError, returns False if an error occurs and True if there are no errors.
' Specify a filename for the log file
SLLogX1.FileName = "C:\Windows\Test.log"
' Specify a title for the log file
SLLogX1.LogTitle = "Log File Title"
' Open the log file for writing
If SLLogX1.Open Then
' Add a comment to the log file
SLLogX1.AddComment "This is a comment"
' Add a line with data to the log file
SLLogX1.AddLine "This is a line with log information"
' Close log file
< Go back