hMailServer IssueTracker

Display defect

ID
355
Short summary BackupSettings.Destination throws exception
Created 2011-04-06 09:39:35
Created by MAllen
Status Not a defect
Priority 3 - Medium
Quick link

Applies to

Found in 5.3.3 build 0

Problem

Accessing the Destination property of the BackupSettings object throws an exception:

Const sAdminPassword = "<ADMINISTRATORPASSWORD>"

Dim oApp
Set oApp = CreateObject("hMailServer.Application")
Call oApp.Authenticate ("Administrator", sAdminPassword)

Dim oSettings
Set oSettings = CreateObject("hMailServer.BackupSettings")
WScript.Echo oSettings.LogFile
WScript.Echo oSettings.Destination

Accessing the LogFile property works without problems. Accessing the Destination property gives: (null): The server threw an exception.

The folder location has been set in the Admin program. Using the UI to browse to the folder shows that the folder exists. If the Admin program is used to make a backup file and then the XML file in the backup file is opened the destination folder is listed there too.

Thanks,

Mike Allen

Issue steps

By martin, 2011-04-06 19:16:25

You can't use the COM API that way. Please see section Accessing an object here:
http://www.hmailserver.com/documentation/latest/?page=com_api_structure

hMailServer Administrator relies on the COM API for all it does. Which means that if you can do it using hMailServer, you can do it using the COM API.


You must be logged on to add a step. Log on now.