New to Telerik UI for WPFStart a free 30-day trial

Represents a dependency property, enabling property value inheritance, styling, and data binding.

Definition

Namespace:Telerik.Windows.Base

Assembly:Telerik.Windows.Controls.RichTextBox.dll

Syntax:

C#
public sealed class RadDependencyProperty

Inheritance: objectRadDependencyProperty

Fields

C#
public static readonly object UnsetValue

Properties

Gets the default metadata for a dependency property.

C#
public RadPropertyMetadata DefaultMetadata { get; }

Indicates whether a property is an attached property.

C#
public bool IsAttached { get; }

Gets the name of the dependency property.

C#
public string Name { get; }

Gets the owner type for the dependency property.

C#
public Type OwnerType { get; }

Gets the type of the property associated with the RadDependencyProperty instance.

C#
public Type PropertyType { get; }

Methods

Returns a hash code for the current instance of the RadDependencyProperty.

C#
public override int GetHashCode()
Returns:

int

A 32-bit signed integer that is the hash code for the current instance.

Overrides: object.GetHashCode()

Registers a dependency property with the specified name, property type, owner type, and metadata.

C#
public static RadDependencyProperty Register(string name, Type propertyType, Type ownerType, RadPropertyMetadata defaultMetadata)
Parameters:namestring

The name of the dependency property.

propertyTypeType

The type of the property being registered.

ownerTypeType

The type that owns the dependency property.

defaultMetadataRadPropertyMetadata

The metadata associated with the dependency property.

Returns:

RadDependencyProperty

A reference to the registered dependency property.

Registers a dependency property in the specified owner type. This method allows you to create a property that supports data binding, animation, and default values.

C#
public static RadDependencyProperty Register(string name, Type propertyType, Type ownerType)
Parameters:namestring

The name of the dependency property as a string.

propertyTypeType

The type of the property being registered.

ownerTypeType

The type that owns the dependency property.

Returns:

RadDependencyProperty

A RadDependencyProperty that can be used to access and set the value of the registered property.

Registers an attached dependency property with the specified parameters.

C#
public static RadDependencyProperty RegisterAttached(string name, Type propertyType, Type ownerType, RadPropertyMetadata defaultMetadata)
Parameters:namestring

The name of the dependency property.

propertyTypeType

The type of the property.

ownerTypeType

The type that owns the property.

defaultMetadataRadPropertyMetadata

The metadata for the property, which can include default values and property changed callbacks.

Returns:

RadDependencyProperty

The registered dependency property.

Registers an attached dependency property with the specified name, property type, and owner type.

C#
public static RadDependencyProperty RegisterAttached(string name, Type propertyType, Type ownerType)
Parameters:namestring

The name of the attached property to register.

propertyTypeType

The type of the attached property.

ownerTypeType

The type that owns this attached property.

Returns:

RadDependencyProperty

A RadDependencyProperty that represents the registered attached property.

Returns a string representation of the current instance of the RadDependencyProperty class.

C#
public override string ToString()
Returns:

string

A string that represents the current RadDependencyProperty instance.

Overrides: object.ToString()