AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Este contenido se ha traducido automáticamente.  Haga clic aquí  para ver la versión en inglés.
Ayuda / WLanguage / Funciones WLanguage / Funciones estándar / Funciones de Windows / Funciones del protocolo SNMP
  • WLanguage procedure
WINDEV
WindowsLinuxJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac Catalyst
Otros
Procedimientos almacenados
Enables the interception of an SNMP trap sent by an agent.
Remark: SNMP interrupt service must be installed on the workstation, and this service must be started.. If the user is an administrator or a power Users, the service starts automatically (unless it has been explicitly disabled).
// Intercept all the traps
nTrapID is int
nTrapID = SNMPTrapEnable("TrapProc", "", "", "")
Sintaxis
<Result> = SNMPTrapEnable(<WLanguage procedure> , <Agent address> , <SNMP community> , <Relevant OID>)
<Result>: Integer
  • Identifier of trap,
  • -1 if an error occurred. ErrorInfo returns more information on the error.
<WLanguage procedure>: Procedure name
WLanguage procedure that will be called whenever the SNMP agent sends a trap message (according to the requested filters). This procedure has the following format:
PROCEDURE <Procedure Name>(<Address>, <Community>, <OID>, <Type>, <Value>)
<Agent address>: Character string
Address of agent whose traps will be received. This address can be specified as follows:
  • IP address in XXX.XXX.XXX.XXX format (125.5.110.100 for example).
  • URL containing the server name (www.windev.com for example). This syntax is recommended.
This agent must be configured to send traps to the computer that runs the application.
If this parameter corresponds to an empty string (""), SNMPTrapEnable will e called on the traps of any agent.
<SNMP community>: Character string
Name of SNMP community of traps. Used to filter the traps according to their community.
If this parameter corresponds to an empty string (""), SNMPTrapEnable will be called on the traps of any community.
<Relevant OID>: Character string
OID affected by the traps. Used to filter the traps according to the relevant OID.
If this parameter corresponds to an empty string (""), SNMPTrapEnable will be called on the traps of any OID.
Observaciones

WLanguage procedure

The WLanguage procedure will be called whenever the SNMP agent sends a trap message (according to the requested filters). This procedure has the following format:
PROCEDURE <Procedure Name>(<Address>, <Community>, <OID>, <Type>, <Value>)
In this code:
  • <Address> is a string. This parameter contains the IP address of the agent that generated the trap.
  • <Community> is a string. This parameter contains the community of the agent that generated the trap.
  • <OID> is an array of strings. This parameter contains the OID of the trap (in numeric format).
  • <Type> is an array of integers. This parameter contains the type of the returned OID.
  • <Value> is an array of strings. This parameter contains the value of the returned OID.
Componente: wd300com.dll
Versión mínima requerida
  • Versión 12
Esta página también está disponible para…
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 28/03/2025

Señalar un error o enviar una sugerencia | Ayuda local