Passy
25-03-2004, 21:52
Non riesco a capire dove stia sbagliando... il compilatore di dice
main1.cpp(11) : Error: not a struct or union type
:muro: :muro: :muro:
#include <stdio.h>
#define DIM_ARRAY_CONTAT_LIST 10
class ContactList
{
private:
Contact *array;
int positionArray;
public:
ContactList();
~ContactList();
void printMenu();
};
ContactList::ContactList()
{
cout << "costruttore\n";
}
ContactList::~ContactList()
{
delete [] array;
cout << "Distruttore\n";
}
void ContactList::printMenu()
{
cout << "Agenda" << " di " << "prova\n";
}
int main(int argc, char * argv[]) {
ContactList clist();
clist.printMenu();
}
Grazie per l'aiuto :gluglu: :gluglu:
main1.cpp(11) : Error: not a struct or union type
:muro: :muro: :muro:
#include <stdio.h>
#define DIM_ARRAY_CONTAT_LIST 10
class ContactList
{
private:
Contact *array;
int positionArray;
public:
ContactList();
~ContactList();
void printMenu();
};
ContactList::ContactList()
{
cout << "costruttore\n";
}
ContactList::~ContactList()
{
delete [] array;
cout << "Distruttore\n";
}
void ContactList::printMenu()
{
cout << "Agenda" << " di " << "prova\n";
}
int main(int argc, char * argv[]) {
ContactList clist();
clist.printMenu();
}
Grazie per l'aiuto :gluglu: :gluglu: