The api.def already has the winapi functions defined for reading/writing ini files.

GetPrivateProfileInt;kernel32!GetPrivateProfileIntA
GetPrivateProfileString;kernel32!GetPrivateProfileStringA
WritePrivateProfileString;kernel32!WritePrivateProfileStringA
GetPrivateProfileSection;kernel32!GetPrivateProfileSectionA
WritePrivateProfileSection;kernel32!WritePrivateProfileSectionA


Never argue with an idiot. They drag you down to their level then beat you with experience