EVENTCREATE – Windows CMD Command
Notice: A non well formed numeric value encountered in /home/future4tech/public_html/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php on line 118
Notice: A non well formed numeric value encountered in /home/future4tech/public_html/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php on line 119
Notice: A non well formed numeric value encountered in /home/future4tech/public_html/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php on line 118
Notice: A non well formed numeric value encountered in /home/future4tech/public_html/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php on line 119
Add a message to the Windows event log, requires administrator rights.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
Syntax EVENTCREATE [/S system [/U username [/P [password]]]] /ID eventid [/L logname] [/SO srcname] /T type /D description Key: /S system The remote system to connect to. /U [domain\]user User credentials under which to execute. /P [password] Password for user, will prompt if omitted. /L logname The event log to create an event in. /T type The type of event to create: SUCCESS, ERROR, WARNING, INFORMATION. /SO source The source to use for the event A text string that represents the application or component that is generating the event. Default='eventcreate' /ID id Event ID, a number between 1 - 1000. /D description Description text for the new event. /? Help |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
Examples: Add an ERROR to the Application log: C:\> EVENTCREATE /T ERROR /ID 1000 /L APPLICATION /D "My application error mesaage" Add a WARNING to the Application log for Application F4TApp: C:\> EVENTCREATE /T WARNING /ID 500 /L APPLICATION /SO F4TApp /D "Running low on diskspace" Add an ERROR to the Application log on Server401: C:\> EVENTCREATE /S Server401 /T ERROR /ID 250 /L APPLICATION /D "Something bad happened" Add an ERROR to the Application log on Server401: C:\> EVENTCREATE /S Server401 /U billg /P password /ID 250 /T ERROR /L APPLICATION /D "Something bad happened" |
Hi there! This post could not be written any better! Reading through this post reminds me of my good old room mate! He always kept talking about this. I will forward this page to him. Fairly certain he will have a good read. Many thanks for sharing!