SmarterMail Pro™ Administration Web Services

svcUserAdmin.UpdateUserForwardingInfo Method 

Updates the specified user's forwarding settings.

public GenericResult UpdateUserForwardingInfo(
   string AuthUserName,
   string AuthPassword,
   string EmailAddress,
   bool DeleteOnForward,
   string ForwardingAddress
);

Parameters

AuthUserName
User name with domain administrative privileges
AuthPassword
Password for AuthUserName
EmailAddress
Email address for the user account to be updated
DeleteOnForward
Determines if message should be deleted after it has been forwarded.
ForwardingAddress
Email address for messages to be forwarded to

Return Value

A GenericResult instance containing the results of the UpdateUserForwardingInfo action.

Example

The following sets a forwarding address and specifies that messages should be deleted after they are sent.

using System;
using svcUserAdmin;

class svcUserAdminUpdateUserForwardingInfo
{
 static void Main()
 {
   svcUserAdmin admin = new svcUserAdmin();
   GenericResult status = admin.UpdateUserForwardingInfo("admin@domain.net",
                                                         "alskdjfhtt",
                                                         "dlindt@domain.net",
                                                         true,
                                                         "dlindt@other.domain.net");

   if(status.Result)
     Console.WriteLine ("User updated");
   else
     Console.WriteLine (status.Message);
  }
}

See Also

svcUserAdmin Class | svcUserAdmin Namespace