Finished issue #4 to log to a log file.