COM API: Examples

Script examples

The below examples are written in VBA. To use them, copy them to a text file, save the file with the extension .vbs and then double-click on the file in the Windows Explorer to run it. Before doing this, make sure that you fully understand the purpose of the script and what effect it may have on your hMailServer installation. We strongly recommend that you run scripts in an test environment before running them on a hMailServer installation used in production.

Trigger examples

Triggers are used to perform certain actions when an event occur in hMailServer. For instance, you can automatically execute a script when a message is delivered or when a backup is performed. The below scripts are examples of such.

Search documentation