Dart SNMP Library 4.0
GetResponses Method
Request to broadcast.
Target broadcast address.
The local network interface to bind to for the operation. Can be NULL/Nothing.
Time to wait for responses to be received.
The threading model the control will use when executing this method.
Object to pass to the Response event; can be NULL/Nothing.
Description
Send a broadcast request and optionally wait for responses.
Syntax
Visual Basic
Public Function GetResponses( _
   ByVal requestMessage As SnmpMessage, _
   ByVal broadcastEP As IPEndPoint, _
   ByVal localEP As IPEndPoint, _
   Optional ByVal timeout As Integer = 1000, _
   Optional ByVal threading As ThreadingConstants = threadingBlock, _
   Optional ByVal userState As Variant _
) As Variant
Parameters
requestMessage
Request to broadcast.
broadcastEP
Target broadcast address.
localEP
The local network interface to bind to for the operation. Can be NULL/Nothing.
timeout
Time to wait for responses to be received.
threading
ValueDescription
threadingAsyncImplements Apartment Model threading without method blocking.
threadingBlockImplements Apartment Model threading with method blocking (UI messages are processed).
threadingFreeImplements Free Model threading with method blocking (UI messages are not processed).
The threading model the control will use when executing this method.
userState
Object to pass to the Response event; can be NULL/Nothing.
Return Value
An array of SnmpMessage responses (if threading is threadingBlock or threadingFree), or NULL/Nothing if threading is threadingAsync.
Remarks

A new socket is created and used each time this method executes.

If localEP is specified, the socket is bound to the specified address family, address and port for the operation. If NULL/Nothing, a socket is created that uses a compatible 'Any' local interface and an ephemeral port.

When used asynchronously (threading is threadingAsync), the Response event will be raised providing access to each response after it has been received, and the Error event will be raised if any error occurs.

Common broadcast addresses:

IPv4 Broadcast: 255.255.255.255

IPv6 Broadcast equivalent (multicast): ff02::1

See Also

Manager Object  | Manager Members


PowerSNMP for ActiveX Documentation Version 4.0
© 2018 Dart Communications. All Rights Reserved.
Send comments on this topic