I am using VC++ 6.0 and do not understand what these errors mean. Could someone please tell me what they mean. Also, since I doubt anyone wants to read 600 lines of code I'll post the part I'm getting the errors on (let me know if more code needs to be posted).
temp is being used again and again, that is why it is so big and ds_entry is of course a dynamacally allocated structure.
Code:
char temp[500];
cout << "Complete...(y) or (n): ";
cin.get(temp, 500, '\n');
cin.ignore(100, '\n');
while(!(temp == 'y' || temp == 'Y' || temp == 'n' || temp == 'N'))
{
strcpy(temp, " ");
cout << "Please enter (y) or (n): ";
cin.get(temp, '\n');
cin.ignore(100, '\n');
cout << endl;
}
ds_entry[eNumber]->complete = new char[strlen(temp) + 1];
strcpy(ds_entry[eNumber]->complete, temp);
strcpy(temp, " ");
cout << endl;
The errors I get are
--------------------Configuration: LongShot - Win32 Debug--------------------
Compiling...
dseen.cpp
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2446: '==' : no conversion from 'int' to 'char *'
Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2040: '==' : 'char [500]' differs in levels of indirection from 'int'
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2446: '==' : no conversion from 'int' to 'char *'
Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2040: '==' : 'char [500]' differs in levels of indirection from 'int'
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2446: '==' : no conversion from 'int' to 'char *'
Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2040: '==' : 'char [500]' differs in levels of indirection from 'int'
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2446: '==' : no conversion from 'int' to 'char *'
Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
C:\Program Files\Microsoft Visual Studio\MyProjects\LongShot\dseen.cpp(218) : error C2040: '==' : 'char [500]' differs in levels of indirection from 'int'
Error executing cl.exe.
dseen.obj - 8 error(s), 0 warning(s)
-----------------------------------------------------------------------
They refer to the temp variable but I do not know how to correct this. What is going on and what is the int in the errors?