Re: Text concatenation
Re: Text concatenation
- Subject: Re: Text concatenation
- From: Chris Garaffa <email@hidden>
- Date: Thu, 03 Mar 2005 18:50:41 -0500
Title: Re: Text concatenation
From: Ronald Hofmann <email@hidden>
Date: Thu, 3 Mar 2005 11:53:29 -0500
>this works: [fullName setStringValue:NSFullUserName()];
>this does not work: [fullName setStringValue: @"Willkommen " + NSFullUserName()];
>What is wrong? Any advices?
Objective-C doesn’t support operator overloading, meaning that + won’t work. What you’re trying to do here is combine two NSString objects. To do this, you need to use one of the methods already mentioned in the “How to concatenate two values?” thread. I’d also recommend reading the NSString and NSMutableString documentation on Apple’s website:
<http://developer.apple.com/documentation/Cocoa/Reference/Foundation/ObjC_classic/Classes/NSMutableString.html>
<http://developer.apple.com/documentation/Cocoa/Reference/Foundation/ObjC_classic/Classes/NSString.html>
--
Chris Garaffa
Technician
TracyLocke
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden