Quote:
Originally Posted by HockeyHippo
This is how I would do it:
Code:
NSString *textbox = [NSString stringWithFormat:@"Enter your text here!"];
|
Depends on what the situation is, but since the text is coming from a text field, it is already a string, so the stringWithFormat is unnecessary.
Code:
message:(@"%@",textbox)
If this is even valid code to begin with, you are again taking something that is already a string, and further formatting it again as a string. Unnecessary.
Code:
NSString *someText = [[self theTextField] text];
message:someText
That's all you need.
Or if you don't want the local variable:
Code:
message: [[self theTextField] text]