Hi, this question is about displaying a text file on the scree, but don't get mad (please).

I have made several functions that display text files, but now I'm having a strange problem. My program handles different type of files, one of them is file_name.mat (materials files). This files are of the type:

5.00 2500.00
7.00 5000.00
9.00 7500.00


Being the left column diameters and the right column breaking loads.

I have a function that creates materials, one that loads materials and one that display the properties of the materials.

I wrote the code for the three of them, it compiled with no errors and it run OK. But when I've run the program again, I tried to create new materials files, and it doesn't work properly. The "only" material that is displayed is the one called acero.mat.
I attach a zipped folder with the whole code, the executable program and three materials files (the one that works and two that don't work).
In case you only need to see the three functions I've mentioned, I include them here:

Code:
void
new_material (void)
{

   char  file_name[8];
   double diameter, load;
   int total, i;

   FILE *output;

   printf("Enter name of the new materials library: ");
   scanf("%s", file_name);
   strcat( file_name, ".mat" );
   output = fopen(file_name, "w");

   printf("Please enter the number of diameters to be entered:  ");

   scanf("%d", &total);

   for(i = 0; i < total; i++)
   {
     printf("Please enter a diameter and its breaking load: ");
     scanf("%lf %lf", &diameter, &load);
     fprintf(output, "%.2f %.2f\n", diameter, load);
   }

   fclose(output);

   printf("\n\nPress any key to continue");
   getch();
   clrscr();
   materials();


}
Code:
void
load_material (void)
{

	// Load an existing material to use with the calculations

   struct ffblk ffblk;
   int done, length;

   clrscr();
   printf("Directory listing of existing materials \n");
   done = findfirst("*.mat",&ffblk,0);
   while (!done)
	 {
	 length = strlen(ffblk.ff_name);
	 ffblk.ff_name[length - 4] = 0;
	 printf("  %s\n", ffblk.ff_name);
	 done = findnext(&ffblk);
	 }


   printf("\nName of the material you want to load ");
   scanf("%s", material);
   strcat( material, ".mat" );
   caracteristics_mat();

}

Code:
void
caracteristics_mat (void)
{

   double getval;  // this variable GETs the VALues from the existing project
   char  file_name[PATH_MAX];
   int i, times;
   FILE *input;

   times = count_lines();

   clrscr();
   strcpy (file_name, material);

   input = fopen(file_name, "r");

   if (( input = fopen(file_name, "r+")) == NULL ) // check it for errors
       {
       printf("There was an error reading from the file!! \n");
       printf("Press any key to continue ");
       getch();
//       main();
       return;

       }

   printf("The caracteristics of the actual material are: \n");
   printf("Diameter	Breaking Load \n\n ");
   for ( i = 0 ; i < times ; i++)
   {
	fscanf(input, "%lf\n", &getval);
	printf("\n  %.2f", getval);
	fscanf(input, "%lf\n", &getval);
	printf("\t\t%.2f\n", getval);

   }

   printf("\n\n		Press any key to continue");
   getch();
   return;

}