IWSDiscoveredService::GetLocalTransportAddress 方法 (wsddisco.h)

擷取本機傳輸 (IP) 位址的字串表示。

語法

HRESULT GetLocalTransportAddress(
  [out] LPCWSTR *ppszLocalTransportAddress
);

參數

[out] ppszLocalTransportAddress

本機傳輸 (IP) 位址的字串表示。 如果無法使用,則為 NULL 。 請勿解除分配輸出字串。

傳回值

這個方法可以傳回下列其中一個值。

可能的傳回值包括但不限於下列各項。

傳回碼 描述
S_OK
方法已順利完成。
E_POINTER
ppszLocalTransportAddressNULL

備註

產生的指標值只適用於 IWSDiscoveredService 物件的存留期。

規格需求

需求
最低支援的用戶端 Windows Vista [僅限傳統型應用程式]
最低支援的伺服器 Windows Server 2008 [僅限傳統型應用程式]
目標平台 Windows
標頭 wsddisco.h (包含 Wsdapi.h)
Dll Wsdapi.dll

另請參閱

IWSDiscoveredService