Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
virtual P6R::P6ERR P6R::p6IWConfig::getConfigBool ( const P6WCHAR pSectionName,
const P6WCHAR pKeyName,
P6BOOL  defaultValue,
P6BOOL pValue 
)
pure virtual

If the section name does not exist then the unnamed section is used as a default.

Returns the string "value" from an existing "name=value" pair in the selected section of a configuration file.

If the value identified by pKeyName does not exist in the section then the defaultValue is returned, and that default value is automatically inserted into the section. In order to save an automatically inserted value to the configuration file on disk make sure that the flushConfigFile has the "withDefaults" flag set to true.

Parameters
pSectionName[ in ] Pointer to string defining the section to write the keyName=value pair
pKeyName[ in ] Pointer to string defining the name part of: "name=value"
defaultValue[ in ] Pointer to a boolean value to return if key does not exist, set to NULL if no default desired.
pValue[ out ] Pointer to a boolean with the value of the key.
Returns
SuccessP6R::eOk 
FailureP6R::eInvalidArgIf pKeyName (or pValue) is NULL or contains a reserved character.
P6R::eNotInitializedA successful call to initialize was not made before this call.
P6R::eFormatErrorIf length of pSectionName + pKeyName is > P6R::MAX_IDENTIFER_SIZE
P6R::eNoMemoryInsufficient memory to look up value.