GetPrivateProfileStringA() [Solved]
I am trying to read info from my .ini file that i put in the same directory as my .exe but it's not reading the file. Here is my code:
God.ini
Any help is appreciated, thanks.
Code:
#include <Windows.h>
#include <iostream>
using namespace std;
int main()
{
char szbuffer[90];
GetPrivateProfileStringA("Question", "Q", "no", szbuffer, 90, "God.ini");
cout<<"The text I have found is: "<<szbuffer<<"\n";
system("PAUSE");
}
Code:
[Question] Q = Thank God.
