Read entry from file.
DWORD Cfg(
CFGFILE cFile,
int n,
LPCSTR* pPath,
LPCSTR* pArgs,
LPCSTR* pOpts,
LPCSTR* pComment,
BOOL* bEnabled
);
Parameters
cFile
- (in) File handle retrieved by previous CfgFileOpen with CFG_LOAD as type.
n
- (in) The number in the file to get.
pPath
- (out) Full path to application to load.
pArgs
- (out) Arguments for the application to load.
pOpts
- (out) The options for the loader.
pComment
- (out) The comment, without leading semicolon.
bEnabled
- (out) True for enabled, FALSE for skip during load.
Return values
ECFG_OK for success or an error code on failure.
Remarks
Gets the elements of the n line in the file. The pointers should not be used to change the strngs or to free the strings in the file.
Errors
ECFG_BADCFGFILE
- File handle out of range or invalid
ECFG_NOMORE
- The file does not contain a line with number n
ECFG_WRONGFILETYPE
- The file handle does not point to a load file
See Also