Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Tossy Kelly
Courses Plus Student 2,069 Pointscannot set username and password from text field inputs
create a user, stage 1 of 4 challenge: Tree House compiler does not accept my solution. '''objective c NSString *username = self.usernameField.text; NSString *password = self.passwordField.text; '''
3 Answers

Gareth Borcherds
9,372 PointsThe challenge doesn't tell you to create a NSString named password and username and store the values to it, it tells you to store the values in properties named username and password, which means that in our .h file we would have something like:
@property (nonatomic, strong) NSString *username;
@property (nonatomic, strong) NSString *password;
So that means we simply need to access that property and set it's value, just like you are doing, but just do it to the properties already created for us. (I know it's confusing...)
- (IBAction)signup:(id)sender {
self.username = self.usernameField.text;
self.password = self.passwordField.text;
}

Alex Cevallos
16,551 Pointshey there! remove the * from *username and *password and try that, could you post the question again?

Soojin Ro
13,331 PointsWhat's with the "objective c" in the beginning?

Gareth Borcherds
9,372 PointsThe objective-c comes from trying to use markdown unsuccessfully, it looks like she used an apostrophe instead of a back tick to create the code blocks that I created below.