GetProfStringList

InstallShield 2020 ยป InstallScript Language Reference

The GetProfStringList function retrieves lists of key names and string values from the specified section of the specified initialization file.

Syntax

GetProfStringList ( szFileName, szSectionName, listKeyNames, listValues );

Parameters

GetProfStringList Parameters

Parameter

Description

szFileName

Specifies the name of the .ini file from which to get the key names and string values. If szFileName is unqualified (that is, if a drive designation and path are not included), InstallShield searches for the file in the Windows folder.

szSectionName

Specifies the name of the .ini file section to search for the key names and string values. The section name should not be enclosed within delimiting brackets ( [ ] ). The search for this name is not case-sensitive.

listKeyNames

Returns a list of key names. The string list identified by listKeyNames must already have been initialized by a call to ListCreate.

listValues

Returns a list of string values. The string list identified by listValues must already have been initialized by a call to ListCreate.

Return Values

GetProfStringList Return Values

Return Value

Description

>= ISERR_SUCCESS (0)

Indicates that the function successfully read the section and inserted key names and string values into the specified lists.

< ISERR_SUCCESS (0)

Indicates that the function could not read the section or insert key names and string values into the specified lists.

Additional Information

GetProfStringList calls the Windows API GetPrivateProfileSection and specifies a 32 KB buffer for the data. Therefore, the function returns only the first 32 KB of data from the section. An installation that needs to handle sections with more than 32 KB of data should call the Windows API GetPrivateProfileSection directly and specify a larger buffer size (and parse the returned information manually).

See Also