Windows Dev Center

Expand Minimize

MediaCapture.StopRecordAsync | stopRecordAsync method

Stops recording.

Syntax


mediaCapture.stopRecordAsync().done( /* Your success and error handlers */ );

Parameters

This method has no parameters.

Return value

Type: IAsyncAction

Returns a IAsyncAction object that is used to control the asynchronous operation.

Remarks

Before playing back a video, the RandomAccessStream should be closed when StopRecordAsync completes.

Examples

The following example shows how to stop a video recording.


// Stop the video capture.
function stopMediaCaptureSession() {
    oMediaCapture.stopRecordAsync().then(function (result) {
        
    }, errorHandler);         
}


Requirements (device family)

Device family

Universal

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.Media.Capture
Windows::Media::Capture [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Capabilities

webcam
microphone

Requirements (operating system)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

Windows.Media.Capture
Windows::Media::Capture [C++]

Metadata

Windows.winmd

Capabilities

webcam
microphone

See also

MediaCapture

 

 

Show:
© 2015 Microsoft