IFaxOutboundRoutingRules::Add method (faxcomex.h)

The IFaxOutboundRoutingRules::Add method adds an outbound routing rule (IFaxOutboundRoutingRule interface) to the collection defined by the IFaxOutboundRoutingRules interface.

Syntax

HRESULT Add(
                long                    lCountryCode,
                long                    lAreaCode,
                VARIANT_BOOL            bUseDevice,
                BSTR                    bstrGroupName,
                long                    lDeviceId,
  [out, retval] IFaxOutboundRoutingRule **pFaxOutboundRoutingRule
);

Parameters

lCountryCode

Type: long

A long value that specifies the country/region code to associate with the outbound routing rule. Specifying frrcANY_CODE will add a rule that applies to any country/region code.

lAreaCode

Type: long

Specifies a long value that indicates the area code to associate with the outbound routing rule. Specifying frrcANY_CODE will add a rule that applies to any area code within the specified country/region code.

bUseDevice

Type: VARIANT_BOOL

Specifies a Boolean value that indicates whether the outbound routing rule points to a single fax device rather than to a group of devices.

bstrGroupName

Type: BSTR

Specifies a null-terminated string that contains the name of the outbound routing group to which the new routing rule belongs. If bUseDevice is set to TRUE, this should be an empty string.

lDeviceId

Type: long

Specifies the device to associate with the outbound routing rule. If bUseDevice is set to FALSE, this parameter is ignored.

[out, retval] pFaxOutboundRoutingRule

Type: IFaxOutboundRoutingRule**

An address of a pointer that receives a IFaxOutboundRoutingRule interface.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

This method can also return remote procedure call (RPC) return values. For more information, see RPC Return Values.

To read or to write to this property, a user must have the farMANAGE_CONFIG access right.

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header faxcomex.h
DLL Fxscomex.dll

See also

IFaxOutboundRoutingRules

Visual Basic Example