Re: seperate String!
Re: seperate String!
- Subject: Re: seperate String!
- From: Jake MacMullin <email@hidden>
- Date: Thu, 5 Feb 2004 09:00:25 +1100
Why not just use a Java StringTokenizer?
Regards,
Jake MacMullin
On 5 Feb 2004, at 3:41 AM, WebObjects EMail wrote:
> hello,
> i want to spilt a String and put the parts in NSArray.
>
> during i try to do that manually i saw an example for that on
>
> http://developer.apple.com/documentation/Cocoa/Reference/Foundation/
> Java/Clas
> ses/NSArray.html#//apple_ref/doc/uid/20000182/
> componentsSeparatedByString_Cla
> ssMethod_NSArray
>
>
>
> NSStringReference list = "wrenches, hammers, saws";
> NSArray listItems = [list.componentsSeparatedByString (", ")];
>
>
>
>
> it does that work for me automatically more or less, but it does not
> work.
>
> I get this
> Error Syntax error on token "[", "{", "+", "-", "--", "++",
> "boolean",
> "void", "byte", "short", "int", "long", "char", "float", "double",
> "(",
> "true", "false", "IntegerLiteral", "LongLiteral",
> "FloatingPointLiteral",
> "DoubleLiteral", "CharacterLiteral", "StringLiteral", "null", "~", "!",
> "super", "this", "new", "Identifier" expected MailRoboter.java
> Online/src
> line 187
>
> Error Stops on "[list" part.
>
> can anybody tell me please why does this code dont work?
> thank you !
> _______________________________________________
> webobjects-dev mailing list | email@hidden
> Help/Unsubscribe/Archives:
> http://www.lists.apple.com/mailman/listinfo/webobjects-dev
> Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.