Re: Format a string
Re: Format a string
- Subject: Re: Format a string
- From: Daryn <email@hidden>
- Date: Tue, 23 Dec 2003 20:45:45 -0600
try
[string stringByPaddingToLength:10 withString:@ startingAtIndex:0];
or
[NSString stringWithFormat:"%-10s"]
On Dec 23, 2003, at 5:08 AM, Daniele wrote:
>
i need to format a bit of strings with an equal number of characters.
>
The formatted string length is 10. Now, for ex, if i have a string of 5
>
chars i need to add other 5 empty chars to format it. Is there a method
>
to do it without using a "for" with appendString method?
>
>
Thanks
>
Daniele
>
_______________________________________________
>
cocoa-dev mailing list | email@hidden
>
Help/Unsubscribe/Archives:
>
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
>
Do not post admin requests to the list. They will be ignored.
[demime 0.98b removed an attachment of type application/pkcs7-signature which had a name of smime.p7s]
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.