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 / Comunicación / Gestión de correos electrónicos
  • Overview of IMAP protocol
  • Using the IMAP protocol
  • Receiving messages by using the IMAP protocol
  • Remarks
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
Overview of IMAP protocol
The IMAP protocol is a standard protocol for managing emails. Unlike the POP3 protocol, the principle for using the IMAP protocol consists in leaving the messages on the messaging server in order to read them from several clients. It includes a specified indicator used to find out whether a message was read. Several messaging servers support both the IMAP protocol and the POP3 protocol.
Remarks:
Using the IMAP protocol

Receiving messages by using the IMAP protocol

To receive emails by using the IMAP protocol
  1. Start an IMAP session by using an emailIMAPSession variable and EmailStartSession.
    Example for starting a session by using an emailIMAPSession variable:
    // Start the messaging session
    MySession is emailIMAPSession
    MySession.ServerAddress = "pop.mycompany.us"
    MySession.Name = "user"
    MySession.Password = "secret"
    EmailStartSession(MySession)
  2. Read the messages on the messaging server:
    • with the EmailGetAll function.
    • with a loop such as:
      Example that uses an Email variable:
      MyMessage is Email
      EmailReadFirst(MySession,MyMessage)
      WHILE NOT MyMessage.Out
      // Place the process of the message read...
      ...
      EmailReadNext(MySession, MyMessage)
      END

      Example that uses the Email structure:
      EmailReadFirst(MySession)
      WHILE NOT Email.Out
      // Place the process of the message read...
      ...
      EmailReadNext(MySession)
      END
    • or with a loop such as (the "NOT READ" keywords are optional and they allow you to browse only the unread messages or all the messages):
      MyMessage is Email
      FOR EACH MyMessage NOT READ OF MySession
      // Place the process of the message read...
      ...
      END
  3. Close the IMAP session with EmailCloseSession.
Remarks
Versión mínima requerida
  • Versión 15
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