Skip to main content

BindableBase.GetPropertyName<T>(Expression<Func<T>>) Method

Returns the name of a property identified by a lambda expression.

Namespace: DevExpress.Mvvm

Assembly: DevExpress.Mvvm.v24.1.dll

NuGet Packages: DevExpress.Mvvm, DevExpress.Win.Navigation

Declaration

public static string GetPropertyName<T>(
    Expression<Func<T>> expression
)

Parameters

Name Type Description
expression Expression<Func<T>>

A lambda expression selecting the property.

Type Parameters

Name
T

Returns

Type Description
String

The name of the property accessed by expression.

Remarks

See BindableBase to learn more.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the GetPropertyName<T>(Expression<Func<T>>) method.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also