So i am trying to read values into an array of structs, from a loop. The file has a certain know input, so each I want to assign each value to a specific slot in the array of structures. However, each time I try to run it, I am told that 'expected expression before ROW' in the lines of the loop.
typedef struct information
{
char Poke[100];
char Type[100];
char Evo[100];
float Height;
float Weight;
int HP;
int Attack;
int Defense;
int SPA;
int SPD;
int Speed;
} ROW[100];
int main()
{
int i;
FILE *ifp;
//open file, set to ifp
while(!feof(ifp))
{
j++;
//Read and store all values
fscanf(ifp, "%s %s", ROW[j].Poke, ROW[j].Type);
fscanf(ifp, "%f %f", ROW[j].Height, ROW[j].Weight);
fscanf(ifp, "%i %i %i %i %i %i", &ROW[j].HP, &ROW[j].Attack,
&ROW[j].Defense,&ROW[j].SPA,&ROW[j].SPD,&ROW[j].Speed);
fscanf(ifp, "%s", &ROW[j].Evo[0]);
}
}