(AutoIt) Retrieve UIDL's from POP3 Server
Retrieve a list of UIDLs from a POP3 server. A UIDL is an identifier consisting of 1 to 70 characters in the range 0x21 to 0x7E, which uniquely identifies a messages within a mailbox and persists across sessions.
; This example requires the Chilkat API to have been previously unlocked.
; See Global Unlock Sample for sample code.
$oMailman = ObjCreate("Chilkat.MailMan")
$oMailman.MailHost = "pop.example.com"
$oMailman.PopUsername = "myLogin"
$oMailman.PopPassword = "myPassword"
$oMailman.MailPort = 995
$oMailman.PopSsl = True
Local $oSa = $oMailman.GetUidls()
If ($oMailman.LastMethodSuccess = False) Then
ConsoleWrite($oMailman.LastErrorText & @CRLF)
Exit
EndIf
; Download each email by UIDL.
Local $sUidl
Local $i = 0
Local $iNumUidls = $oSa.Count
While $i < $iNumUidls
$sUidl = $oSa.GetString($i)
ConsoleWrite($sUidl & @CRLF)
$i = $i + 1
Wend
|