Returns a collection of strings containing the messages of errors, parse errors, or warnings encountered while executing a query with the Execute or ExecuteBatch methods.
Read-only property.
value = objLogQuery.errorMessages;
JScript example:
var oLogQuery = new ActiveXObject("MSUtil.LogQuery"); // Make sure that parse error messages are collected oLogQuery.maxParseErrors = 100; // Create query text var strQuery = "SELECT sc-bytes INTO C:\\output.csv FROM ex040528.log"; // Execute query oLogQuery.ExecuteBatch( strQuery ); // Check if errors occurred if( oLogQuery.lastError != 0 ) { WScript.Echo("Errors occurred!"); var oMessages = new Enumerator( oLogQuery.errorMessages ); for(; !oMessages.atEnd(); oMessages.moveNext()) { WScript.Echo("Error message: " + oMessages.item()); } } else { WScript.Echo("Executed successfully!"); }VBScript example:
Dim oLogQuery Dim strQuery Set oLogQuery = CreateObject("MSUtil.LogQuery") ' Make sure that parse error messages are collected oLogQuery.maxParseErrors = 100 ' Create query text strQuery = "SELECT sc-bytes INTO C:\output.csv FROM ex040528.log" ' Execute query oLogQuery.ExecuteBatch strQuery ' Check if errors occurred If oLogQuery.lastError <> 0 Then WScript.Echo "Errors occurred!" For Each strMessage In oLogQuery.errorMessages WScript.Echo "Error Message: " + strMessage Next Else WScript.Echo "Executed succesfully!" End If
© 2004 Microsoft Corporation. All rights reserved.
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator at webmaster@systemmanager.forsenergy.ru to inform them of the time this error occurred, and the actions you performed just before this error.
More information about this error may be available in the server error log.
Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.