Wintertree Software Inc.

Wintertree Spelling Server

Home Site index Contact us Catalog Shopping Cart Products Support Search

You are here: Home > Support > Wintertree Spelling Server > How to access the Wintertree Spelling Server event log


How to access the Spelling Server event log

Wintertree Spelling Server records significant events in its event log. Information recorded in the event log can be helpful in diagnosing configuration problems. When you contact the Support Group with Spelling Server related problems, you can save time by including the contents of the event log. This document describes how to access the event log. Note that the event log is configured in different ways in different versions of Wintertree Spelling Server; be sure to use the approach appropriate for the version you are using.

Applies to: Version 1.8 and later

The event log is accessed by calling the GetEventLog method. You can display the event log contents in a browser window using code similar to the following:

Dim wss, eventLog
Set WSS = Server.CreateObject("SpellingServer.SpellCheck")
eventLog = wss.GetEventLog()
Response.Write("Spelling Server event log:<BR>" & eventLog & "<BR>")

In a VB.NET application:

Dim wss as new SpellingServer()
Response.Write("Spelling Server event log:<BR>" & wss.GetEventLog() & "<BR>")

In a C# application:

Response.Write("Spelling Server event log:<BR>" + SpellingServer.GetEventLog() + "<BR>");

Applies to: Version 1.7.3 and 1.7.4

When the CheckText method returns a negative error code, it sets the value of the otherWord parameter to the contents of the event log (limited to 10K characters). You can display the event log contents in a browser window by forcing CheckText to return an error code:

Dim cursor, word, otherWord
result = WSS.CheckText(CStr(""), CLng(999999), CLng(0), CStr(""), CStr(""), cursor, word, otherWord)
If (result < 0) Then
Response.Write("<P><FONT COLOR=RED>Spelling server error " & result & "</FONT><BR>")
Response.Write("Diagnostic information:<BR>")
Response.Write(otherWord)
End If

In the example code above, an unknown language id (999999) is passed to the CheckText method to force it to return -7.

The event log information returned through the otherWord parameter is formatted for HTML display. Lines are separated with the <BR> markup. To convert the log information to text format, replace "<BR>" with CR-LF.

Applies to: Version 1.7

The event log is created only if the EventLogPath string value is defined in the registry. This value is defined in the registry when you install Wintertree Spelling Server. EventLogPath contains the path to a folder on the server's file system where Wintertree Spelling Server's event logs can be created. By default, this path is c:\Program Files\Wintertree Spelling Server\EventLog.

The folder indicated by the EventLogPath string value must exist. Permissions assigned to this folder must allow any user or application to write to it. If the folder is empty, then most likely permissions on your system are preventing Wintertree Spelling Server from creating or writing to event log files. To get around this, you can use regedit to set EventLogPath to a writable folder, such as c:\WINNT\Temp or c:\Windows\Temp. Note that you may need to restart your server after changing the EventLogPath string value or changing permissions on the folder.

See the next section ("Apples to: Version 1.4 and later") for further information.

Applies to: Version 1.4 - 1.6

The log files are created in the directory indicated by the EventLogPath setting (HKEY_LOCAL_MACHINE\Software\Wintertree\SpellingServer\EventLogPath). If this setting is not defined, the event logs are written in a directory named "eventlog" which is a subdirectory of the directory where WintertreeSpellingServer.dll resides (however, in version 1.7 and later, if EventLogPath is not defined, event logging is disabled). When you install Wintertree Spelling Server, the EventLogPath value is automatically set to c:\Program Files\Wintertree Spelling Server\eventlog.

The event log consists of (up to) 31 files, named "day01.txt" to "day31.txt". Each file corresponds to a day of the month. Events logged on the 6th of the month are written to "day06.txt", for example. When a log file is reused, events recorded on the same day the previous month are deleted. This arrangement keeps an historical record of significant events (up to one month's worth) without consuming excessive disk space. If you want to keep event logs for longer than one month, you can either make a backup of each file or change the EventLogPath setting each month.

Most significant events involving configuration problems occur when Wintertree Spelling Server starts, which is usually when the Start method is called or when the first spelling check takes place. If you are using the event logs to diagnose configuration problems, start with the log file corresponding to the day of the month when Wintertree Spelling Server started.

If the event log files are not created, the problem is most likely due to permissions. You can solve the problem by creating an EventLogPath string value in the registry which points to a different folder where files may be written. Details about the EventLogPath string value are contained in the user's guide.

Applies to: Version 1.3 and earlier

In version 1.3 and earlier, the event logs are not created automatically. Instead, an event log is written only if a string value named HKEY_LOCAL_MACHINE\Software\Wintertree\SpellingServer\LogFile is defined in the registry. The value is set to the path and name of a file where diagnostic information will be written when Wintertree Spelling Server runs.


Home Site index Contact us Catalog Shopping Cart Products Support Search


Copyright © 2015 Wintertree Software Inc.