共用方式為


DevicePairingRequestedEventArgs.AcceptWithPasswordCredential 方法

定義

接受 PairingRequested 事件,並將裝置與應用程式配對。 需要使用者名稱和密碼才能進行配對。

public:
 virtual void AcceptWithPasswordCredential(PasswordCredential ^ passwordCredential) = AcceptWithPasswordCredential;
void AcceptWithPasswordCredential(PasswordCredential const& passwordCredential);
public void AcceptWithPasswordCredential(PasswordCredential passwordCredential);
function acceptWithPasswordCredential(passwordCredential)
Public Sub AcceptWithPasswordCredential (passwordCredential As PasswordCredential)

參數

passwordCredential
PasswordCredential

物件,封裝使用者名稱和密碼,以嘗試配對裝置。

Windows 需求

裝置系列
Windows 10, version 1903 (已於 10.0.18362.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v8.0 引進)

適用於