Click or drag to resize
Cimbalino ToolkitObservableBaseSetPropertyT Method (T, T, ExpressionFuncT)
Assigns a new value to a property and raises the PropertyChanged event if the value changed.

Namespace: Cimbalino.Toolkit.Helpers
Assembly: Cimbalino.Toolkit.Core (in Cimbalino.Toolkit.Core.dll) Version: 2.2.1.0 (2.2.1.0)
Syntax
C#
protected virtual bool SetProperty<T>(
	ref T field,
	T value,
	Expression<Func<T>> propertyExpression
)

Parameters

field
Type: T
The field storing the property's value.
value
Type: T
The property's new value.
propertyExpression
Type: System.Linq.ExpressionsExpressionFuncT
An expression identifying the property that changed.

Type Parameters

T
The property type.

Return Value

Type: Boolean
true if the property value changed; otherwise, false.
Version Information

Portable

Supported in: 4.5

Windows

Supported in: 10.0, 8.1

Windows Phone

Supported in: 8.1

Windows Phone Silverlight

Supported in: 8.1, 8.0
See Also