Hello,
I use InstallShield 8 under WindowsXP.
There I try to read the section OBJECT_LIST1 from my Ini-file containing all keys from 000 up to 478:
[OBJECT_LIST1]
000=CLASS_ID(00008),CLASS_VERSION(00000)
001=CLASS_ID(00009),CLASS_VERSION(00000)
...
478=CLASS_ID(00007),CLASS_VERSION(00001)
Unfortunately GetProfStringList only reads 456 entries of this section (keys 000 up to 455). The return value of GetProfStringList is 0 (Indicates that the function successfully read the section and inserted key names and string values into the specified lists.), but ListCount returns 456 and not 478:
LIST listKeys, listTemp;
listKeys = ListCreate(STRINGLIST);
listTemp = ListCreate(STRINGLIST);
nResult = GetProfStringList(szIniFrom, szFromSectionName, listKeys,
listTemp);
// nResult = 0
nResult = ListCount ( listKeys );
// nResult = 456
Is this a bug of GetProfStringList? Or is anything wrong with my source code?
Any help is appreciated...
This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
GetProfStringList doesn't read a whole section
Started by
Habel
, Jan 12 2011 12:06
4 replies to this topic
Posted 13 January 2011 - 09:57
I'm not sure, maybe there's a (undocumented?) limit of interal buffer-size. Do you get more entries if you shorten the text (for testing purposes)?
Stefan Krüger
InstallSite.org twitter facebook
Posted 19 January 2011 - 15:58
Thanks for your tip!
When I shorten the text, the whole section is read. There really seems to be a limit of internal buffer-size for GetProfStringList().
Do you know any workaround?
When I shorten the text, the whole section is read. There really seems to be a limit of internal buffer-size for GetProfStringList().
Do you know any workaround?
Posted 20 January 2011 - 18:23
You could try to proptype the Windows API and call it directly - which won't help if the limitation is in Windows (and not in InstallShield).
Stefan Krüger
InstallSite.org twitter facebook
Posted 20 January 2011 - 18:24
Or you could read it as an ordinary text file, maybe that would work. In this case you have to parse the text line by line.
Stefan Krüger
InstallSite.org twitter facebook