Calling functions from different files.
Hi all,
I'm not very sure about linking but I managed to create a project (using VC++ 6) and all my source are in the specific folder which was created for that project.
Can I know how can I do a function call of another .cpp file that will be compiled and put into the same build (.exe)?
Example:
Code:
void accessories(void)
{
int choice;
do
{
system("cls");
cout << "==================" << endl;
cout << "1.) Converter" << endl;
cout << "2.) Back to Main Menu" << endl;
cout << "==================" << endl;
cout << "Please select: ";
cin >> choice;
switch (choice)
{
case 1 : cout << "Converter" << endl;
// Goes to another file which stores other stuff
break;
}
} while (choice != 3 );
}
The comment in bold is what i meant by function call of another file. So, when it does a function call, it'll read from a function in the converter.cpp file.
Thanks in advance :)