View Single Post
Old 02-20-2007, 06:00 AM   #3 (permalink)
weewun
 
True Techie

Join Date: Dec 2004

Posts: 138

weewun is on a distinguished road

Default

sorry i dont think i said what i was meaning too... what im wanting to do is have a class 'data' then initialise, like 'int numbe;' called person, then pass through the entire class...
e.g.
.................................................. ........
class data {
int itemone;
int itemtwo;
};

int anotherfunction(data *aperson)//pass the whole class through
{
aperson.itemone=10;
return;
}


int main(){
data person;
anotherfunction(&person);
}
.................................................. .........

i am coding on a PS2 development kit, so the debug is not ver helpful, but for the code above it would say:
request for member `itemone' in `aperson', which is of non-aggregate type `data *'


cheers for the help
weewun is offline