ProjectionManager.StartProjectingAsync | startProjectingAsync method

Applies to Windows only

Asynchronously sends a window (app view) to the projector or other secondary display.

Syntax


public:
static IAsyncAction^ StartProjectingAsync(
  int projectionViewId, 
  int anchorViewId
)

Parameters

projectionViewId

Type: Number [JavaScript] | System.Int32 [.NET] | int32 [C++]

The new ID of the window to be displayed by the projector or other secondary display.

anchorViewId

Type: Number [JavaScript] | System.Int32 [.NET] | int32 [C++]

The ID of the original window before projection.

Return value

Type: IAsyncAction

The asynchronous results of the operation. Use this to determine when the async call is complete.

Remarks

If this method succeeds, an existing window (app view) is placed on a secondary display, if one is detected. Otherwise, the window is placed on the primary display. This window can only be accessed from an ASTA UI thread.

The moved window has its own ASTA UI thread and associated CoreWindow. Always use thread-safe methods, such as window.postMessage for JavaScript apps or the CoreDispatcher event messaging API for C# and C++ apps, when communicating between the windows.

Either the current app view window or the projection view window must be active for this call to succeed. The view ID can be obtained for the current app view with ApplicationView.Id. For a specific app view managed by the app, call ApplicationView.GetApplicationViewIdForWindow with the CoreWindow for the app view.

Requirements

Minimum supported client

Windows 8.1

Minimum supported server

Windows Server 2012 R2

Minimum supported phone

None supported

Namespace

Windows.UI.ViewManagement
Windows::UI::ViewManagement [C++]

Metadata

Windows.winmd

See also

ProjectionManager

 

 

Show:
© 2014 Microsoft