JAMS Developer Guide
GetProperty(String,Object) Method


Genghis Namespace > Preferences Class > GetProperty Method : GetProperty(String,Object) Method
The property name.
Use slash (/) to logically separate groups of settings.
The default property value. If no previous property exists, or the preferences store is unavailable, this value will be returned.
Gets a property
Syntax
'Declaration
 
Public Overloads Function GetProperty( _
   ByVal name As System.String, _
   ByVal defaultValue As System.Object _
) As System.Object
'Usage
 
Dim instance As Preferences
Dim name As System.String
Dim defaultValue As System.Object
Dim value As System.Object
 
value = instance.GetProperty(name, defaultValue)
public System.object GetProperty( 
   System.string name,
   System.object defaultValue
)

Parameters

name
The property name.
Use slash (/) to logically separate groups of settings.
defaultValue
The default property value. If no previous property exists, or the preferences store is unavailable, this value will be returned.

Return Value

Returns the property value (with the same type as defaultValue).
Remarks
The return type is converted to the same type as the defaultValue argument before it is returned. Therefore, this must be a type supported by the System.Convert class. The supported types are: Boolean, Char, SByte, Byte, Int16, Int32, Int64, UInt16, UInt32, UInt64, Single, Double, Decimal, DateTime and String.
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

Preferences Class
Preferences Members
Overload List