Export (0) Print
Expand All

XamlSchemaContext.TryGetCompatibleXamlNamespace Method

Returns the success or failure of a request for a compatible XAML namespace. A successful request reports that XAML namespace as an out parameter.

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

abstract TryGetCompatibleXamlNamespace : 
        xamlNamespace:string * 
        compatibleNamespace:string byref -> bool  
override TryGetCompatibleXamlNamespace : 
        xamlNamespace:string * 
        compatibleNamespace:string byref -> bool


Type: System.String

The xmlns string for the XAML namespace to be checked for a compatible result.

Type: System.String

When this method returns, the xmlns string for a compatible XAML namespace request. This might be identical to xamlNamespace if the method returns false.

Return Value

Type: System.Boolean
true if compatibleNamespace contains a usable result; otherwise, false.


xamlNamespace is a null reference (Nothing in Visual Basic).

Internally, this method uses the following lookup order:

  1. An internally implemented compatibility dictionary, which may have been populated by an earlier lookup.

  2. The XmlnsCompatibleWithAttribute parameter evaluation.

If no other compatible namespace is discovered and this method returns false, the compatibleNamespace parameter output might have the same value as the xamlNamespace input.

.NET Framework

Supported in: 4.5, 4

.NET Framework Client Profile

Supported in: 4

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

© 2014 Microsoft