More trouble with header files...

For some reason I'm completely inept with using multiple source files. If anyone can show me what I am doing wrong here I would be very grateful.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// InfoGather.h
#ifndef INFOGATHER_H_INCLUDED
#define INFOGATHER_H_INCLUDED
#include<iostream>
#include<string>

using namespace std;

string pName(playerName;);




#endif // INFOGATHER_H_INCLUDED



1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

// InfoGather.cpp
#include "InfoGather.h"
#include<iostream>
#include<string>

using namespace std;

string pName(playerName;)
{
    cout << "Please enter your name: "
    cin >> playerName;

    return 0;
}


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// main.cpp
#include<iostream>
#include<string>
#include "InfoGather.h"

using namespace std;


int main()
{
    string pName(playerName;);

    return 0;
}


Topic archived. No new replies allowed.