Microsoft Operations Manager

LogSummary Method

The LogSummarymethod returns a variant array containing rows of MTA log summary information for the specified MTA log type.

[VBScript]
MTALogAnalyzer.LogSummary(MTA_Type Variant, DataOut Variant,
RowCount Variant, [TopNN Variant])

Parameters

MTA_Type

Specifies the type of MTA log summary to return. Valid values include the following:

DataOut
Variant array that contains MTA log summary information for a server.
RowCount
Number of MTA log summary information rows returned.
TopNN
Specifies that this method should only return rows with the top NN MTA summary entries, as measured by message count and message size. This parameter is optional.

Return Value

Variant

Examples

The following example shows how to get the previous day's top 100 SMTP Out Sender log summary results for the EXCHSERVER1 Exchange server using the Someone mailbox.

[VBScript] 
Const PI_MTA_SMTP_OUT_SENDER = 1001
Dim objMTALogAnalyzer, vntData
Dim lngRowCount, lngIndex, lngMsgCount, lngMB
Dim strError

Set objMTALogAnalyzer = CreateObject("McExchg.MTALogAnalyzer")

If objMTALogAnalyzer.LogonToMAPI("EXCHSERVER1", "Someone") Then
	If objMTALogAnalyzer.ProcessPrevDaysLog() Then
		If objMTALogAnalyzer.LogSummary(PI_MTA_SMTP_OUT_SENDER,
vntData, lngRowCount, 100) Then
			For lngIndex = 0 to lngRowCount - 1
				strObject = vntData(0, lngIndex)
				lngMsgCount = vntData(1, lngIndex)
				lngMB = vntData(2, lngIndex)
				' Do something with summary information
			Next
		Else
			strError = objMTALogAnalyzer.GetError()
		End If
	 Else
		strError = objMTALogAnalyzer.GetError()
	 End If
Else
	strError = objMTALogAnalyzer.GetError()
End If

Set objMTALogAnalyzer = Nothing

Requirements

Windows NT/2000: Requires Windows 2000 or later
Version: Requires MOM 1.0 SP1

See Also

MTALogAnalyzer Object


Did you find this information useful? Please send your suggestions and comments about the documentation to momsdk@microsoft.com.