Well, what i'm trying to do is use cin.getline with my char pointer of 255 characters, take a look at the code below:
#include <cstdlib>
#include <iostream>
#include <fstream>
#include <conio.h>
using namespace std;
char * pChar[255];
pChar = new char[255];
void newPointer()
{
delete pChar;
pChar = new char[255];
}
int main(int argc, char *argv[])
{
cout << "Enter a line of text: ";
cin.getline(pChar, 255);
void newPointer();
cout << "Enter another line of text: ";
cin.getline(pChar, 255);
delete pChar;
cin.get();
return EXIT_SUCCESS;
}
Am I doing something wrong or what? If you want I can copy and paste the error codes I get from it, they're confusing. Thanks, I appreciate all the help I can get.
=D