I'm finding myself stuck trying to simply get a userInfo class's sets to work, but every time I try and compile with simple code like this in my application file:

userInfo stuff;


It gives me one of those 'undefined symbol' errors and references to the userInfo::setId function:

Undefined first referenced
symbol in file
userInfo::setId(std::basic_string<char, std::char_traits<char>, std::allocator<char> >)/var/tmp//cc1wjEkh.o
ld: fatal: Symbol referencing errors. No output written to a.out
collect2: ld returned 1 exit status

The sets are implemented as follows in my implementation file:

void userInfo::setId(string anId) { id = anId;}
void userInfo::setPassword(string passwd) {password = passwd;}

Not sure if I'm missing some vital or obvious factor about the userInfo sets. Any help would be MUCH appreciated.

6 Years
Discussion Span
Last Post by Moschops

void userInfo::setId(string anId) { id = anId;}

What's id? Is that definitely a member of the userInfo class

Edited by Moschops: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.