Compartilhar via


BthRemoteNameQuery (Windows CE 5.0)

Send Feedback

This function queries the name of a remote Bluetooth device.

Note   To preserve Win32 compatibility, consider using the Winsock equivalent of this function. To do so, pass SO_BTH_SET_READ_REMOTE_NAME as the optname value in setsockopt.

int BthRemoteNameQuery(  BT_ADDR* pba,  unsigned int cBuffer,  unsigned int* pcRequired,  WCHAR* szString);

Parameters

  • pba
    [in] Pointer to the Bluetooth address of a device whose name is to be queried.
  • cBuffer
    [in] The size of the buffer. The buffer must contain enough space for a 0-terminated string. The recommended size is 256 characters.
  • pcRequired
    [out] Pointer to the number of wchars required.
  • szString
    [in, out] On input, the buffer in which to store the device name. On output, the resulting string.

Return Values

This function returns ERROR_SUCCESS when it completes successfully.

A return value of ERROR_SERVICE_NOT_ACTIVE indicates that the hardware is not inserted or that the Bluetooth stack is not present.

A return value of ERROR_INSUFFICIENT_BUFFER indicates that the buffer is too small.

Other standard error codes may be returned as appropriate.

Remarks

For more information about this function, see the Remote_Name_Request part of the Bluetooth Core Specification.

Requirements

OS Versions: Windows CE.NET 4.2 and later.
Header: Bt_api.h.
Link Library: Btdrt.lib.

See Also

Bluetooth OS Functions | Bluetooth Application Development | WSALookupServiceBegin | WSALookupServiceNext | WSALookupServiceEnd

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.