Share via


IXRVisualHost::SetPosition (Compact 2013)

3/28/2014

This method sets the current on-screen position of this visual host.

Syntax

virtual HRESULT STDMETHODCALLTYPE SetPosition(  INT XCoordinate,  INT YCoordinate) = 0;

Parameters

  • XCoordinate
    [in] Integer that indicates the x-coordinate (left) for the new upper-left corner of this visual host.
  • YCoordinate
    [in] Integer that indicates the y-coordinate (top) for the new upper-left corner of this visual host.

Return Value

Returns an HRESULT that indicates success or failure.

Returns XR_E_INVALID_THREAD_ACCESS if this method was called from a thread that is different from the thread on which the system was initialized. A visual host can only be accessed on the thread that it was created on. Most XAML for Windows Embedded APIs can only be accessed from a single thread.

Returns XR_E_INVALID_STATE if this method was called on an object in an invalid state, such as a host that was already destroyed or a dialog box that was closed without calling EndDialog.

.NET Framework Equivalent

None.

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

IXRVisualHost