Hi i have a function like this
while(fscanf(fp,"\n%d\t%s\t%s\t%X%X\t%d\t  \n",&record.Index,record.Name,record.Empcode,&record.CSN_MSB,&record.AccessRights)!=EOF)
 {
  printf("\nIndex: %d\nEmployee Name: %s\nEmpcode: %s\nCSN: %X\nAccessRights: %d\n",record.Index,record.Name,record.Empcode,record.CSN_MSB,record.AccessRights);
  sprintf(CSN_MSB_LSB,"%X", record.CSN_MSB);
  if(strncmp(CSN_MSB_LSB,str,8)==0)
  found=1;       
 }
in this code my fscanf is reading only one line from file pointer fd, i want to read all the lines from the file. how i can i do this with same fscanf function or else any alternative which contains the same parameter list for the fscanf function please suggest me