Author: bonusnet | Posted on: 9/7/2009 9:13:14 AM | Views : 339

 Hi,
Below code perform succesfully as follow
 ' Write the information to the event log.
Dim Log As New EventLog()
Log.Source = "DivisionPage"
Log.WriteEntry(err.Message, EventLogEntryType.Error)
after I go to registry editor (regedit), locate key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\Application and create a new key with the source name as DivisionPage
I tried to perform Custom Log as follow,
' Open the log. If the log does not exist, it will be created automatically.
Dim Log As New EventLog("ProseTech")
Log.Source = "DivisionPage"
Log.WriteEntry(err.Message, EventLogEntryType.Error)
I got an error as follow,
The source 'DivisionPage' is not registered in log 'ProseTech'. (It is registered in log 'Application'.) " The Source and Log properties must be matched, or you may set Log to the empty string ...

Go to the complete details ...