ITAddress2::get_PreferredPhones method (tapi3if.h)
The get_PreferredPhones method returns a collection of phone objects corresponding to the phone devices that are preferred for use with this address.
This method is intended for Visual Basic and scripting applications. C/C++ applications should use the EnumeratePreferredPhones method instead.
Syntax
HRESULT get_PreferredPhones(
[out] VARIANT *pPhones
);
Parameters
[out] pPhones
Pointer to a VARIANT containing an ITCollection of ITPhone interface pointers.
Return value
This method can return one of these values.
Value | Meaning |
---|---|
|
Method succeeded. |
|
The pPhones parameter is not a valid pointer. |
|
There is not enough memory to allocate the collection object. |
Remarks
A phone device declares itself as being preferred to an address or set of addresses by returning address/line IDs using phoneGetID with device class tapi/line. If no phones are available for use with this address, the method produces an empty collection and returns S_OK.
TAPI calls the AddRef method on the ITPhone interface returned by ITAddress2::get_PreferredPhones. The application must call Release on the ITPhone interface to free resources associated with it.
Requirements
Requirement | Value |
---|---|
Target Platform | Windows |
Header | tapi3if.h (include Tapi3.h) |
Library | Uuid.lib |
DLL | Tapi3.dll |