Write to Windows event log: Difference between revisions
Content added Content deleted
Line 447: | Line 447: | ||
(log-warning "Warning: nothing went wrong.") |
(log-warning "Warning: nothing went wrong.") |
||
</lang> |
</lang> |
||
=={{header|Scala}}== |
|||
The following works on Windows 10 with elevated (administrative) permission: |
|||
<lang Scala>object RegisterWinLogEvent extends App { |
|||
import sys.process._ |
|||
def eventCreate= Seq("EVENTCREATE", "/T", "SUCCESS", "/id", "123", "/l", "APPLICATION", "/so", "Scala RegisterWinLogEvent", "/d", "Rosetta Code Example" ).!! |
|||
println(eventCreate) |
|||
println(s"\nSuccessfully completed without errors. [total ${scala.compat.Platform.currentTime - executionStart} ms]") |
|||
}</lang> |
|||
=={{header|REXX}}== |
=={{header|REXX}}== |