Windows apps
Collapse the table of content
Expand the table of content
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

UIElement.TransformToVisual Method


Returns a transform object that can be used to transform coordinates from the UIElement to the specified object.

Namespace:  System.Windows
Assembly:  System.Windows (in System.Windows.dll)

public GeneralTransform TransformToVisual(
	UIElement visual


Type: System.Windows.UIElement
The object to compare to the current object for purposes of obtaining the transform.

Return Value

Type: System.Windows.Media.GeneralTransform
The transform information as an object. Call GeneralTransform.Transform on this object to get a practical transform.

In WPF, this method exists on the Visual class. Silverlight does not use Visual in its public object model. Silverlight implements several Visual-related APIs on the UIElement class instead.


Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1, Windows Phone OS 7.0

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

© 2017 Microsoft