I'm looking at the script for getting delivery queue detail using PowerShell script. I did search in google but I'm not able to find any of script.If someone could you please helpe me
Use this forum if you have problems with a hMailServer script, such as hMailServer WebAdmin or code in an event handler.
2 posts • Page 1 of 1
You can try this:
I tried it but I don't have anything in my queue so I can't say if it works or not. It comes up empty for me, but it did something.
Code: Select all
$hMSAdminPass = "supersecretpasssword" $hMS = New-Object -COMObject hMailServer.Application $hMS.Authenticate("Administrator", $hMSAdminPass) | Out-Null $hMSDeliveryQueue = $hMS.Status.UndeliveredMessages() $hMSDeliveryQueue