Closed chucklu closed 5 years ago
Hi @chucklu If the cmdlet successfully creates a new log, then nothing is returned by design. This reflects the underlying EventlLog API which also doesn't return anything on success. It looks like you ran the command on 6 and it succeeded with no output as expected. When you ran the command again on 5.1 it got an error because the log already existed. If you run the command on 6 again, you should now see the same error as you do on 5.1. Can you confirm that this is the case?
@BrucePay Sorry, I misunderstood the source and the logname.
Hi @SteveL-MSFT @BrucePay , After I installed this module, I can use command in powershell 6.1
Get-EventLog -Newest 5 -LogName "Application"
. But when I use command in powershell 6.1New-EventLog -Source "SupperSocketService" -LogName "TestLog" -MessageResourceFile "C:\Test\TestApp.dll"
, nothing happened. No error info and no success info.