Isn't the drawback to using WSH the fact that the source is "WSH" and not the name of your app? And how do you write events to the Event Log?
>If you're running on an NT system, you could log errors to the NT Event log using the WSH 2.0 Wscript.Shell automation object fairly easily, there's a LogEvent method available:
>
>oShell = CREATEOBJ('Wscript.Shell')
>oShell.LogEvent(nIntType,cLogMessage,cTargetMachine)
>
>nIntType may be one of:
>
>
Number Event Type
> 0 Success
> 1 Error
> 2 Warning
> 4 Information
> 8 Audit_Success
> 16 Audit_Failure
>
>cLogMessage can be a string of up to 255 bytes
>
>You can specify a different machine's NetBIOS name as the third parameter. If omitted under NT, the current system's Event Log is used. Win9x writes to a local log in the System directory called WSH.LOG, and will ignore the third parameter in all cases.