I keep getting this loop but my program compiles.
#include "RAHIM.H"
#define HEAD1 "GO-BROKE-AND-LAYOFF MANUFACTURING COMPANY"
#define HEAD2 "EMPLOYEE_NAME HOURS PAY_RATE GROSS_PAY PENSION_PLAN NET_PAY"
#define LINE "-----------------------------------------------------------------"
#define INFILE"P05.DAT"
int main()
{char employee_name[16];
double hours_worked,hourly_rate,gross_pay,pension_plan,net_pay,
total_hours_worked=0,total_gross_pay=0,total_net_pay=0;
i.e. a statically declared array of 16 chars, and then used it like this:
Infile.get(employee_name[17]);
You're indexing out of the bounds of the array here (valid indexes are 0 to 15). I see other interesting things going on in your code, but perhaps that will give you a starting point.
Feel free to post your next attempt (using the <> code tags please!).