ConfigurationKeySet.cnt2Id(Int32) 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.
Retrieves the ID of the nth configuration key.
public:
virtual int cnt2Id(int _cnt);
public virtual int cnt2Id (int _cnt);
abstract member cnt2Id : int -> int
override this.cnt2Id : int -> int
Public Overridable Function cnt2Id (_cnt As Integer) As Integer
Parameters
- _cnt
- Int32
The index of the configuration key, which must be between 1 and the number of configuration keys.
Returns
The ID of the specified configuration key.
Remarks
To find the number of configuration keys, use the cnt method. In general, the index and ID will differ, because not all the IDs are used.
The following example demonstrates the cnt method.
ConfigurationKeySet configKeySet = new ConfigurationKeySet();
DictConfigurationKey dictConfigurationKey;
int i;
configKeySet.loadSystemSetup();
for (i=1; i<= configKeySet.cnt(); i++)
{
setPrefix('Disabled configurationkeys');
if (!configKeySet.enabled( configKeySet.cnt2Id(i) ))
{
dictConfigurationKey =
new DictConfigurationKey(configKeySet.cnt2id(i));
info (dictConfigurationKey.name());
}
}