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
Returns the list of folders:
  • for an IMAP session.
  • WINDEVWEBDEV - Server code found in the Outlook messaging software.
    Reminder This function does not list folders in Outlook Express.
MaSession is emailIMAPSession
...
// Liste des dossiers
ListeDossier = EmailListFolder(MaSession, LstFolderAll + LstFolderType)
// ListeDossier contient par exemple :
// "Dossiers personnels" + TAB + dossierPersonnel + RC + ...
// "Dossiers personnels\Boîte de réception" + ...
// TAB + dossierRéception + RC + ...
// "Dossiers personnels\Boîte de réception\Travail" + ...
// TAB + dossierGénérique + RC + ...
// "Dossiers personnels\Boîte de réception\Personnel" + ...
// TAB + dossierGénérique + RC + ...
WINDEVWEBDEV - Server code
// Ouverture de la session
IDSession = EmailStartOutlookSession("MonProfil")
...
// Liste des dossiers
ListeDossier = EmailListFolder(IDSession)
// ListeDossier contient par exemple :
// "Dossiers personnels" + RC + ...
// "Dossiers personnels\Boîte de réception" + RC + ... 
// "Dossiers personnels\Boîte de réception\Travail" + RC + ...
// "Dossiers personnels\Boîte de réception\Personnel" + RC + ...
Syntax
<Result> = EmailListFolder(<Session> [, <Option>])
<Result>: Character string
List of folders. The different folders are separated by CR characters (Carriage Return). The format of the result depends on the constant used:
LstFolderAll<Name of Folder1> + CR + <Name of Folder2> + CR +...
LstFolderNormal
(Default value)
<Name of Folder1> + CR + <Name of Folder2> + CR +...
LstFolderSorted<Name of Folder1> + CR + <Name of Folder2> + CR +...
LstFolderType<Name of Folder1> + TAB + <Type of Folder1> + CR + <Name of Folder2> + TAB + <Type of Folder2> + CR +...
Where:
<Nom DossierX> Full name of file. For example: "Personal folders\Inbox\Work".
<Type DossierX> Type of file listed. This parameter can correspond to:
  • draft folder: Draft folder
  • folderContact Contact and contact group folder
  • trash folder: Deleted items folder
  • folderSend Folder for emails waiting to be sent
  • folderSent Sent emails folder
  • generic folder: Generic folder (folder created by users)
  • folderNewspaper Newspaper folder
  • dossierNote: Notes folder
  • PersonalFolder: Root of the "PersonalFolders" folder
  • folderReception Email received folder
  • dossierRendezVous: Appointments folder
  • task folder: Task folder
If an error occurs, the ErrorOccurred variable is set to True. To get more details on the error, use ErrorInfo with the errMessage constant.
<Session>: Character string, integer, or emailOutlookSession or emailIMAPSession variable
Identifier of the current email session. This identifier can be:
<Option>: Optional Integer constant (or combination of constants)
Indicates:
  • the type of list to perform:
    LstFolderAllList of all folders.
    LstFolderNormalList of folders containing emails only ("In-box", "Elements sent", ...).
  • the sort mode of the list:
    LstFolderSortedList sorted in alphabetical order.
  • the display of the folder type:
    LstFolderTypeReturns the type and name of folders (option not supported by the IMAP protocol)
By default, all folders containing emails are listed. This list is not sorted in alphabetical order and it contains the name of each folder only.
Remarks
To handle:
Component: wd300com.dll
Minimum version required
  • Version 11
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 03/27/2025

Send a report | Local help