Sample code for 30+ languages & platforms
PowerShell

Transition from MailMan.LoadMime to Email.SetFromMimeText

Provides instructions for replacing deprecated LoadMime method calls with Email.SetFromMimeText.

Chilkat PowerShell Downloads

PowerShell
Add-Type -Path "C:\chilkat\ChilkatDotNet47-x64\ChilkatDotNet47.dll"

$success = $false

$mailman = New-Object Chilkat.MailMan

# ...
# ...

$mimeText = "...."

# ------------------------------------------------------------------------
# The LoadMime method is deprecated:

$emailObj = $mailman.LoadMime($mimeText)
if ($mailman.LastMethodSuccess -eq $false) {
    $($mailman.LastErrorText)
    exit
}

# ...
# ...

# ------------------------------------------------------------------------
# Do the equivalent using Email.SetFromMimeText.

$email = New-Object Chilkat.Email
$success = $email.SetFromMimeText($mimeText)
if ($success -eq $false) {
    $($email.LastErrorText)
    exit
}