tldr/pages.zh/windows/eventcreate.md

21 lines
641 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# eventcreate
> 在事件日志中创建自定义条目.
> 事件ID可以是1到1000之间的任意数值.
- 在日志中创建一个具有给定id1-1000的新事件:
`eventcreate /t {{success|error|warning|information}} /id {{id}} /d "{{消息}}"`
- 在特定事件日志中创建事件:
`eventcreate /l {{日志名}} /t {{类型}} /id {{id}} /d "{{消息}}"`
- 为新创建的事件指定来源:
`eventcreate /so {{来源名}} /t {{类型}} /id {{id}} /d "{{消息}}"`
- 在远程计算机的事件日志中创建事件:
`eventcreate /s {{主机名}} /u {{用户名}} /p {{密码}} /t {{类型}} /id {{id}} /d "{{消息"}}`