Why doesn't my program run?

#include <limits>
#include <iostream>
#include <cmath>
#include <string>
#include <iomanip>
#include <ctime>
#include <fstream>

using namespace std;

const double COLORADDED = 0.10;
const double REGFRAME = 0.15;
const double FANCYFRAME = 0.25;
const double CARDBOARD = 0.02;
const double GLASS = 0.07;
const double TAX = 0.0925;

int main()
{

string employeeName, customerName, color;
char frameType, colorChoice, rerun;
double width, height, subTotal, squareArea, glassPrice, total;
double cardBoard, colorPrice, tax, frame;
void Print(string name, double width, double height, double subTotal, double squareArea, double glassPrice, double total, double cardBoard, double colorPrice, double tax, double frame);
void PrintPaySlip(ostream& out, string name, double width, double height, double subTotal, double squareArea, double glassPrice, double total, double cardBoard, double colorPrice, double tax, double frame);

do
{


cout << "name:";
getline(cin,employeeName);

if(employeeName.length() !=0)
{
cout << "Customor's name: ";
getline(cin,customerName);
}
else
{
cout << "*** Invalid name. *** Can't be empty.";
return 0;
}

if(customerName.length() !=0)
{
cout << "Frame Width [3-72]: ";
cin >> width;
}
else
{
cout << "*** Invalid Width ***";
return 0;
}

if (width >= 3 || width <= 72)
{
cout << "Frame Height [3-72]: ";
cin >> height;
}
else
{
cout << "*** Invalid Height ***";
return 0;
}

if (height >= 3 || height <= 72)
{
squareArea = (height * width);
glassPrice = (squareArea * GLASS);
cardBoard = (squareArea * CARDBOARD);
cout << "Frame Type [R/F]: ";
cin >> frameType;
}
else
{
cout << "*** Invalid Frame Type ***";
return 0;
}

//ask for frame type or so invalid input
switch (frameType)
{
case 'f':
case 'F': cout << "Special Frame Color? ";
cin >> colorChoice;
cout << endl;
switch (colorChoice)
{
case 'y':
case 'Y':cout << " > ";
cin >> color;
cout << ">>>>> Processing...." << endl;
colorPrice = (COLORADDED*height + COLORADDED*width);
frame = (FANCYFRAME*height + FANCYFRAME*width);
subTotal = (glassPrice + cardBoard + frame + colorPrice);
break;
case 'n':
case 'N': frame = (FANCYFRAME*height + FANCYFRAME*width);
subTotal = (glassPrice + cardBoard + frame);
color = "white";
break;
default : cout << "*** Not Valid **";
return 0;
}
break;
case 'r':
case 'R': cout << "Special Frame Color? ";
cin >> colorChoice;
cout << endl;
switch (colorChoice)
{
case 'y':
case 'Y':cout << " > ";
cin >> color;
cout <<">>>>> Processing...." << endl;
frame = ((REGFRAME * height) + (REGFRAME * width));
colorPrice = ((COLORADDED * height) + (COLORADDED * width));
subTotal = (glassPrice + cardBoard + frame + colorPrice);
break;

case 'n':
case 'N':frame = ((REGFRAME * height) + (REGFRAME * width));
subTotal = (glassPrice + cardBoard + frame);
color = "white";
break;

default : cout << "*** Not Valid ***";
return 0;
}
break;
}
// calculate total
cout << endl;
tax = subTotal * TAX;
total = subTotal + tax;


//time code
struct tm* timeinfo;
time_t rawtime;
time(&rawtime);
timeinfo = localtime(&rawtime);

void Print(string name, double width, double height, double subTotal, double squareArea, double glassPrice, double total, double cardBoard, double colorPrice, double tax, double frame)
{
ofstream outfile;
string filename = employeeName +"'s Invoice.txt";
outfile.open(filename.c_str());

PrintPaySlip(cout, employeeName, width, height, subTotal, squareArea, glassPrice, total, cardBoard, colorPrice, tax, frame);
PrintPaySlip(outfile, employeeName, width, height, subTotal, squareArea, glassPrice, total, cardBoard, colorPrice, tax, frame);


}



void PrintPaySlip (ostream& out, string name, double width, double height, double subTotal, double squareArea, double glassPrice, double total, double cardBoard, double colorPrice, double tax, double frame)


{


out << fixed << setprecision(2) << showpoint;
out << setw(50) << setfill(' ') << "" << endl;
out << setfill(' ');
out << "NATHAN BROTHERS" << setw(35) << right << setfill(' ') << "Purchase Order" << endl<<endl;

out << "714-756-1234" << endl<<endl;


{
for (int i = 0; i < 50; i++)
out << char(45);
out<<endl<<endl;
}
out << "Date/Time: "; cout << asctime(timeinfo); cout << endl;
out << "Your order was taken by "<< employeeName<<endl<<endl;
out << "Customer: "<< customerName<<endl<<endl;

{
for (int i = 0; i < 50; i++)
out << char(61);
out << endl<<endl;
}

out << setfill('.');
out << left << setw(42) << "Frame Height " << " " << setfill(' ') << right << setw(6) << height << endl << endl;
out << setfill('.');
out << left << setw(42) << "Frame Width " << " " << setfill(' ') << right << setw(6) << width << endl << endl;
out << setfill('.');
out << left << setw(42) << "Frame Type " << " " << setfill(' ') << right << setw(6) << frameType << endl << endl;
out << setfill('.');
out << left << setw(42) << "Color " << " " << setfill(' ') << right << setw(6) << color << endl << endl;

{
for (int i = 0; i < 50; i++)
out << char(45);
out<<endl<<endl;
}

out << setfill(' ');
out << left << setw(15) << "Frames" << right << setw(25) << "$" << right << setw(10) << frame << endl << endl;
out << left << setw(15) <<"Cardboard Back" << right << setw(25) << "$" << right << setw(10) << cardBoard << endl << endl;
out << left << setw(15) << "Glass" << right << setw(25) << "$" << right << setw(10) << glassPrice << endl << endl;

{
for (int i = 0; i < 50; i++)
out << char(45);
out<<endl<<endl;
}

out << right << setw(34) << "SUBTOTAL" << right << setw(6) << "$" << right << setw(10) << subTotal << endl << endl;
out << right << setw(34) << "TAX(9.25%)" << right << setw(6) << "$" << right << setw(10) << tax << endl << endl;
out << right << setw(34) << "TOTAL" << right << setw(6) << "$" << right << setw(10) << total << endl << endl;
{
for (int i = 0; i < 50; i++)
out << char(61);
out<<endl<<endl;
}
out<<"THANK YOU for your order"<<endl<<endl;


out<< "Do you have more employees?";
cin>>rerun;
cin.ignore( std::numeric_limits<streamsize>::max(), '\n' );
}

while(rerun == 'y'|| rerun=='Y');

}
I think you are missing the closing brace for main.
Also do not define functions inside main.
So I closed the bracket for main and it wasn't the problem. How am I supposed to take out my Print function from main?
Topic archived. No new replies allowed.