ConfigFileHelperGetSecureSetting Method

Gets a secure string value of a configuration file key.

Definition

Namespace: Configuration.Helper
Assembly: Configuration.Helper (in Configuration.Helper.dll) Version: 2.0.5
C#
public static SecureString GetSecureSetting(
	string configFile,
	string sectionName,
	string key
)

Parameters

configFile  String
Full path and name of the configuration file.
sectionName  String
Name of the section containing the key.
key  String
Key of the value to return.

Return Value

SecureString
If the key cannot be retrieved then the return value will have a length of zero.

Exceptions

ArgumentExceptionThrown when the sectionName parameter is empty.

See Also