(PowerShell) Transition from MailMan.GetUidls to MailMan.FetchUidls
Provides instructions for replacing deprecated GetUidls method calls with FetchUidls. Note: This example requires Chilkat v11.0.0 or greater.
Add-Type -Path "C:\chilkat\ChilkatDotNet47-x64\ChilkatDotNet47.dll"
$mailman = New-Object Chilkat.MailMan
# ...
# ...
# ------------------------------------------------------------------------
# The GetUidls method is deprecated:
$sa = $mailman.GetUidls()
if ($mailman.LastMethodSuccess -eq $false) {
$($mailman.LastErrorText)
exit
}
# ...
# ...
# ------------------------------------------------------------------------
# Do the equivalent using FetchUidls.
# Your application creates a new, empty StringTable object which is passed
# in the last argument and filled upon success.
$st = New-Object Chilkat.StringTable
$success = $mailman.FetchUidls($st)
if ($success -eq $false) {
$($mailman.LastErrorText)
exit
}
|