Re: cString

2008-11-27 Thread Scott Andrew
Depending on you neeeds you can use cStringUsingEncoding: or if you  
are ok using UTF8 encoded strings -UTF8String. The NSString  
documentation clearly states this.


Scott

On Nov 27, 2008, at 11:48 AM, Luca Ciciriello wrote:



Hi All.Recently I've installed the new Xcode 3.1.2 and I've removed  
my old Xcode 2.5.I've compiled with Xcode 3.1.2 (using the optional  
compiler GCC 4.2) one of the my Objective-C++ project. No problem,  
but I've got a warning about the code line: string elem =  
[[[gridArrayObjc objectAtIndex:i] stringValue] cString];The warning  
is: "Warning: 'cString' is deprecated [...]". Well, in which way can  
I modify my code line in order to eliminate the deprecated cString? 
Thanks in advance for any answer.Luca.www.mitosrl.com

_
Win £1000 John Lewis shopping sprees with BigSnapSearch.com
http://clk.atdmt.com/UKM/go/117442309/direct/01/___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/scottandrew%40roadrunner.com

This email sent to [EMAIL PROTECTED]


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]


RE: cString

2008-11-27 Thread Luca Ciciriello

Thanks Mattias, UTF8String has solved my problem.Bye.Luca> Date: Thu, 27 Nov 
2008 20:54:11 +0100> From: [EMAIL PROTECTED]> To: [EMAIL PROTECTED]> Subject: 
Re: cString> CC: cocoa-dev@lists.apple.com> > On Thu, Nov 27, 2008 at 20:48, 
Luca Ciciriello> <[EMAIL PROTECTED]> wrote:>>>> Hi All.Recently I've installed 
the new Xcode 3.1.2 and I've removed my old Xcode 2.5.I've compiled with Xcode 
3.1.2 (using the optional compiler GCC 4.2) one of the my Objective-C++ 
project. No problem, but I've got a warning about the code line: string elem = 
[[[gridArrayObjc objectAtIndex:i] stringValue] cString];The warning is: 
"Warning: 'cString' is deprecated [...]". Well, in which way can I modify my 
code line in order to eliminate the deprecated cString?> > Hi Luca,> > Have you 
noticed that you can hold down the ALT modifier key and> double click on a 
method name to bring up the relevant documentation> for that method? If you do 
that on "cString", you'll see something> like this:> > "Returns a 
representation of the receiver as a C string in the default> C-string encoding. 
(Deprecated in Mac OS X v10.4. Use> cStringUsingEncoding: or UTF8String 
instead.)"> > Regards> Mattias
_
See the most popular videos on the web 
http://clk.atdmt.com/GBL/go/115454061/direct/01/___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]


Re: cString

2008-11-27 Thread Mattias Arrelid
On Thu, Nov 27, 2008 at 20:48, Luca Ciciriello
<[EMAIL PROTECTED]> wrote:
>
> Hi All.Recently I've installed the new Xcode 3.1.2 and I've removed my old 
> Xcode 2.5.I've compiled with Xcode 3.1.2 (using the optional compiler GCC 
> 4.2) one of the my Objective-C++ project. No problem, but I've got a warning 
> about the code line: string elem = [[[gridArrayObjc objectAtIndex:i] 
> stringValue] cString];The warning is: "Warning: 'cString' is deprecated 
> [...]". Well, in which way can I modify my code line in order to eliminate 
> the deprecated cString?

Hi Luca,

Have you noticed that you can hold down the ALT modifier key and
double click on a method name to bring up the relevant documentation
for that method? If you do that on "cString", you'll see something
like this:

"Returns a representation of the receiver as a C string in the default
C-string encoding. (Deprecated in Mac OS X v10.4. Use
cStringUsingEncoding: or UTF8String instead.)"

Regards
Mattias
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]


cString

2008-11-27 Thread Luca Ciciriello

Hi All.Recently I've installed the new Xcode 3.1.2 and I've removed my old 
Xcode 2.5.I've compiled with Xcode 3.1.2 (using the optional compiler GCC 4.2) 
one of the my Objective-C++ project. No problem, but I've got a warning about 
the code line: string elem = [[[gridArrayObjc objectAtIndex:i] stringValue] 
cString];The warning is: "Warning: 'cString' is deprecated [...]". Well, in 
which way can I modify my code line in order to eliminate the deprecated 
cString?Thanks in advance for any answer.Luca.www.mitosrl.com
_
Win £1000 John Lewis shopping sprees with BigSnapSearch.com
http://clk.atdmt.com/UKM/go/117442309/direct/01/___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]