SimpleDynamicMemberAccessor.TryGetProperty<T>(Object, String, T) 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.
Attempts to get a value of a property of given object instance
.
public:
generic <typename T>
bool TryGetProperty(System::Object ^ instance, System::String ^ propertyName, [Runtime::InteropServices::Out] T % propertyValue);
public bool TryGetProperty<T> (object instance, string propertyName, out T propertyValue);
member this.TryGetProperty : obj * string * 'T -> bool
Public Function TryGetProperty(Of T) (instance As Object, propertyName As String, ByRef propertyValue As T) As Boolean
Type Parameters
- T
Return type of the propertyName
property.
Parameters
- instance
- Object
Object instance whose property is being gotten.
- propertyName
- String
The case sensitive name of the property.
- propertyValue
- T
Return value of the property.