Houdah - ML Pierre Bernard wrote:

NSMutableString *dateFormat = [NSMutableString stringWithString: [dateFormatter dateFormat]];

[dateFormat replaceOccurrencesOfString:@"d" withString:@"dd" options: 0 range:NSMakeRange(0, [dateFormat length])];


Unrestricted replacement of meta-characters doesn't handle quoted meta-characters in the formatting string. If you're going to do this task using meta-character replacement, you'll have to parse the entire format, correctly handling the quoted parts.

http://unicode.org/reports/tr35/tr35-6.html#Date_Format_Patterns

http://developer.apple.com/documentation/Cocoa/Conceptual/ DataFormatting/Articles/dfDateFormatting10_4.html#//apple_ref/doc/uid/ TP40002369

  -- GG

_______________________________________________

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 arch...@mail-archive.com

Reply via email to