Article Preview
Buy Now
REVIEW
LogIt
Issue: 1.6 (June/July 2003)
Author: Brian Jones
Article Description: No description available.
Article Length (in bytes): 3,988
Starting Page Number: 8
Article Number: 1603
Related Web Link(s):
http://myweb.cableone.net/schasj/
http://myweb.cableone.net/schasj/Macintosh.htm
http://myweb.cableone.net/schasj/LogIt%20Page.htm
Excerpt of article text...
Keeping a log of your program's progress can be a key element in debugging a piece of code or in tracking the effects of program changes on program performance. There are simple ways to implement very basic logging in REALbasic, but LogIt provides a small, stable, relatively advanced solution that will fulfill the needs of almost any developer on almost any project.
LogIt is installed by including a module and a window in your project and setting some global variables at startup. If the user chooses to log to the window rather than to a file, a discreet floating window is shown with all log entries. The developer appends entries with their timestamp automatically included by simply passing a user-defined string to a function called
WriteLog
. The logging process can be customized by setting four globals.The first global,
LoggingFormat
, allows users to select whether they want to timestamp according to the time of day, in units of ticks or microseconds, or not at all. SettingLogRelativeTo
allows the user to specify the time since the log opened, since the last log entry was made, or since system startup. The LogIt window will show ifLoggingToWindow
is set totrue
, otherwise the log will be saved to a file on the Desktop. Finally, settingLogImmediately
allows the user to decide between the security of saving the log with each entry or the speed increase of keeping it in a cache at the risk of losing the log data if there is a problem.
...End of Excerpt. Please purchase the magazine to read the full article.