Quote:

Thanks Richard for the code... but onl reads sections

How would one use this to read both SECTIONS and real KEY data




Well this is just for enumerating the sections (and entry keys) where they might exceed the 32KB limit.

Once you have the section and/or key you would use the stock ReadProfileString() to read it.

To re-iterate my comments in the last post, unless your section is likely to contain more than 32KB of entry names, it is better to use ReadProfileString() to enumerate the entries once you've used udfEnumHugeIni() to get the section names.

For example:
Code:
Break ON
$=SetOption("Explicit","ON")

Dim $sIni,$sSections,$sEntries,$sSection,$sEntry

$sIni=".\hugeini.ini"

$sSections=udfEnumHugeIni($sIni)
If @ERROR "["+@ERROR+"] "+@SERROR+@CRLF EndIf

For Each $sSection In Split($sSections,Chr(10))
"SECTION: "+$sSection+@CRLF

$sEntries=udfEnumHugeIni($sINI,$sSection)
If @ERROR "["+@ERROR+"] "+@SERROR+@CRLF EndIf

For Each $sEntry in Split($sEntries,Chr(10))
" ENTRY: "+$sEntry+@CRLF
" Data: "+ReadProfileString($sINI,$sSection,$sEntry)+@CRLF
Next
Next

Exit 0