NextPreferenceKey()

Syntax

Result = NextPreferenceKey()
Description
Retrieves information about the next key found in the enumeration started with ExaminePreferenceKeys(). To get the name and the value of the key, use PreferenceKeyName() and PreferenceKeyValue().

Parameters

None.

Return value

Nonzero if more keys are available in the current enumeration, zero otherwise.

Example

  ; Open a preference file
  OpenPreferences(#PB_Compiler_Home +"Examples\Sources\Data\test.pref")
  
  ; Select a group
  PreferenceGroup("window")
  
  ; Examine keys in the group 'window'  
  ExaminePreferenceKeys()
  While  NextPreferenceKey() ; While a key exists
    MessageRequester("Key group 'window'", PreferenceKeyName() + " = " + PreferenceKeyValue())  ; Display the key with its data
  Wend
  
  ; Close the preference file
  ClosePreferences()  

See Also

ExaminePreferenceKeys(), PreferenceKeyName(), PreferenceKeyValue()

Supported OS

All

<- NextPreferenceGroup() - Preference Index - OpenPreferences() ->