Submits discovery or monitoring data back to the Management Server and ends the execution of the script.
MOMScriptAPI.Return(vVal) |
Parameters
Parameter | Type | Description |
---|---|---|
vVal |
Variant |
The object to submit. |
Return Value
None.
Remarks
The Return method supports the following parameter types:
- MOMPropertyBag
object: After the name-value pairs have been created, the property
bag is submitted by using the Return method. After the
Return method has been called, no more name-value pairs can
be created and submitted from the script. An example of this method
is in the MOMScriptAPI.CreatePropertyBag
method.
- MOMDiscoveryData
object: After the discovery data has been created, the data is
submitted by using the Return method. After the
Return method has been called, no more discovery data can be
created and submitted from the script. An example of this method is
in the MOMScriptAPI.CreateDiscoveryData
method.
- Simple values, such as a single numerical value.
If you must send multiple values back to the Management Server, use an instance of the MOMPropertyBag object as the parameter.
An example of the Return method is in the CreateDiscoveryData method and the CreatePropertyBag method.
The Return method submits the data packet to Operations Manager. If you are running this script outside of the Operations Manager, this XML string can be displayed in a console window. The Management Pack must be prepared and inserted as a rule to be run from Operations Manager.
Requirements
Platforms: Requires Windows Server 2003, Windows Vista, or Windows Server 2008
Version: Requires Operations Manager 2007
See Also
Send comments about this topic to Microsoft.