BindableObject.SetValue Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
SetValue(BindableProperty, Object) |
Sets the value of the specified bindable property. |
SetValue(BindablePropertyKey, Object) |
Sets the value of the specified bindable property. |
SetValue(BindableProperty, Object)
- Source:
- BindableObject.cs
- Source:
- BindableObject.cs
Sets the value of the specified bindable property.
public:
void SetValue(Microsoft::Maui::Controls::BindableProperty ^ property, System::Object ^ value);
public void SetValue (Microsoft.Maui.Controls.BindableProperty property, object value);
member this.SetValue : Microsoft.Maui.Controls.BindableProperty * obj -> unit
Public Sub SetValue (property As BindableProperty, value As Object)
Parameters
- property
- BindableProperty
The bindable property on which to assign a value.
- value
- Object
The value to set.
Exceptions
Thrown when property
is null
.
Remarks
If property
is read-only, nothing will happen.
Applies to
SetValue(BindablePropertyKey, Object)
- Source:
- BindableObject.cs
- Source:
- BindableObject.cs
Sets the value of the specified bindable property.
public:
void SetValue(Microsoft::Maui::Controls::BindablePropertyKey ^ propertyKey, System::Object ^ value);
public void SetValue (Microsoft.Maui.Controls.BindablePropertyKey propertyKey, object value);
member this.SetValue : Microsoft.Maui.Controls.BindablePropertyKey * obj -> unit
Public Sub SetValue (propertyKey As BindablePropertyKey, value As Object)
Parameters
- propertyKey
- BindablePropertyKey
The key that identifies the bindable property to assign the value to.
- value
- Object
The value to set.
Exceptions
Thrown when propertyKey
is null
.
Thrown when the bindable property identified by propertyKey
is read-only.