Visual Basic (Usage) | ![]() |
---|---|
Dim instance As DataValue Dim defaultValue As T Dim value As T value = instance.GetValue(Of T)(defaultValue) |
C# | |
---|---|
public T GetValue<T>( T defaultValue ) |
Parameters
- defaultValue
- The default value to return if any error occurs.
Type Parameters
- T
- The type of object.
Return Value
The value.
Does not throw exceptions; returns the caller provided value instead.
Extracts the body from an ExtensionObject value if it has the correct type.
Checks the StatusCode and returns an error if not Good.
Target Platforms: Windows 7/8/10, Windows Server 2003/2008/2012/2015, .NET4.x