ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Communication / Managing emails
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
Manages a progress bar while sending and receiving emails.
Remark: Sending or IncomingData emails includes both the email message and the files attached to the email.
Example
// Affichage de la jauge dans le champ JAUGE_JaugeEmail (Syntaxe 1)
EmailProgressBar(JAUGE_JaugeEmail)
...
// Annulation de cette jauge
EmailProgressBar("")
WINDEV
// La jauge est gérée par la procédure GestionProgression (Syntaxe 2)
EmailProgressBar(GestionProgression)
// Procédure
PROCEDURE GestionProgression(TotalOctet, TotalTransmis)
Message("Transfert en cours: " + TotalTransmis + " / " + TotalOctet)
JAUGE_JaugeEmail = TotalTransmis / TotalOctet
WINDEV
// La jauge est gérée par l'événement ProgressionEmail (Syntaxe 3)
EmailProgressBar("ProgressionEmail")

// -- Code d'initialisation de la fenêtre
Event(GestionBarre, "*.*", "ProgressionEmail")
// -- Procédure
PROCEDURE GestionBarre(TotalOctet, TotalTransmis)
Trace("Transfert en cours: " + TotalTransmis+ " / " + TotalOctet)
Syntax

Displaying the progress bar in a Progress Bar control Hide the details

EmailProgressBar(<Name of Progress Bar control> [, <Frequency>])
<Name of Progress Bar control>: Character string
Name of the Progress Bar control where the progress bar will be displayed. This control must exist in the current window.
If this parameter corresponds to an empty string (""), the current progress bar is canceled.
<Frequency>: Optional integer
Specifies the frequency for refreshing the progress bar (in bytes). The default frequency is set to 10.000 (the progress bar is refreshed every 10 KB).
Caution: this frequency is for guidance only.

Managing the progress bar via a procedure Hide the details

EmailProgressBar(<WLanguage procedure> [, <Frequency>])
<WLanguage procedure>: Procedure name
Name of the WLanguage procedure that will manage the progress bar.
This procedure has the following format:
PROCEDURE <Nom de la procédure> (<Total>, <Progression>)
where:
  • <Total> is the number of bytes to transmit or to receive.
  • <Progress> is the number of bytes already transmitted or received.
These parameters can be used in the procedure at any time.
If this parameter corresponds to an empty string (""), the current progress bar is canceled.
<Frequency>: Optional integer
Specifies the frequency for refreshing the progress bar (in bytes). The default frequency is set to 10,000 (the procedure is called every 10 KB).
Caution: this frequency is for guidance only.
WINDEV

Managing the progress bar via an event Hide the details

EmailProgressBar(<Event name> [, <Frequency>])
<Event name>: Character string
Name of the event that will be run during the progress. This event must be processed by Event. In this case:
  • the wParam parameter (the 1st parameter of the event) will correspond to the amount of bytes to send
  • the lParam parameter (2nd parameter of the event) will correspond to the amount of bytes already sent.
    If this parameter corresponds to an empty string (""), the current progress bar is canceled.
<Frequency>: Optional integer
Specifies the frequency for refreshing the progress bar (in bytes). The default frequency is set to 10,000 (the event is triggered every 10 KB).
Caution: this frequency is for guidance only.
Remarks
  • EmailProgressBar must be called before the read and send email functions.
  • EmailProgressBar can only be used for the SMTP, POP3 and IMAP protocols. This function is not available in Outlook.
Related Examples:
WD Mail Complete examples (WINDEV): WD Mail
[ + ] This application is an email client developed in WINDEV. It is based on the Email objects.
This email client is used to retrieve and send emails by using the POP, IMAP and SMTP protocols.
You have the ability to apply filters to the incoming emails.

The application can also be used to manage several email accounts. The writing of an email is based on the HTML edit control.
Component: wd300com.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 09/24/2024

Send a report | Local help