Quote
[Messages]
1=Hi
2=How
3=Are
4=You?
1=Hi
2=How
3=Are
4=You?
You couldn't get 1-4 statically using GetPrivateProfileString, but with GetPrivateProfileSection you could! Because it runs through and collects them all (although I'm unsure how), which is why I'm posting here. :)
How do you extract the information from GetPrivateProfileSection?
Thanks in advance (I'm trying to figure out right now). :unsure:
----------------------------- EDIT ------------------------------------
for (int x = 0; x < 500; x++) {
printf("%c", test[x]);
if (test[x] == '\0') {
printf("\n"); // New line - the string ended
if (test[x + 1] == '\0') { break; }
}
}
Fixed! :) I'm such a retard... Thanks, sorry for the post.
It clearly states here (http://msdn.microsof...348(VS.85).aspx) on MSDN:
Quote
lpReturnedString [out]
A pointer to a buffer that receives the key name and value pairs associated with the named section. The buffer is filled with one or more null-terminated strings; the last string is followed by a second null character.
A pointer to a buffer that receives the key name and value pairs associated with the named section. The buffer is filled with one or more null-terminated strings; the last string is followed by a second null character.
Sorry for posting, thanks again!!! <3












