PlayToReceiver.StartAsync 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
開始接收播放至命令。
public:
virtual IAsyncAction ^ StartAsync() = StartAsync;
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncAction StartAsync();
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncAction StartAsync();
function startAsync()
Public Function StartAsync () As IAsyncAction
傳回
啟動作業完成時所呼叫的異步處理程式。
- 屬性
備註
如需建立軟體播放收件者的範例,請參閱 媒體傳播。
// Advertise the receiver on the local network and start receiving commands
await receiver.StartAsync();
// Prevent the screen from locking
if (display == null)
display = new Windows.System.Display.DisplayRequest();
display.RequestActive();
StatusTextBlock.Text = "'" + receiver.FriendlyName + "' started.";
' Advertise the receiver on the local network and start receiving commands
Await receiver.StartAsync()
' Prevent the screen from locking
If display Is Nothing Then
display = New Windows.System.Display.DisplayRequest()
display.RequestActive()
StatusTextBlock.Text = "'" & receiver.FriendlyName & "' started."
End If