iphone - Converting a date (string) into another date format (string) -
I'm happy if there is any one can help me, a newbie question.
For example, I have an NSMutableArray:
{JobID = 109302930; Subject = "test theme"; Submit = "2009-09-15 17:27:34"; }
Now I am trying to create a square in my table view and want to group my records on the basis of "formatted" data. For example,
16th May'09 ========== Item one item b 18th May'09 =========== Item C Item G 20th May'09 ========== Item Jade Item K
I (from an XML data source) after this NSMutableArray with function (NSString *) elementName namespaceURI: (NSString *) namespaceURI qualifiedName: (NSString *) QName {currentElement = [pic] [NSString alloc init]]; If ([elementName isEqualToString: @ "subject"]) {[item setObject: currentSubject forKey: @ "topic"]; } And if ([elementName isqualToString: @ "job_id"]) {[item set object: current jubbed farke: @ "job image"] ;; } Else if ([elementName isEqualToString: @ "submit_date"]) {// I want to insert date values into standard MySQL date format (YYYY-MM-HH) instead of a formatted path. [Item set object: for current job submission: @ "submit"]; [Add Preview Data Object: Item]; }}
As I commented in the above code, in which YYYY-MM-DD instead of HH: II: SS, I want to add the date of formatted date string Are there. How can I do this?
Thank you for your help.
You want to use it to make it use NSDate
, Then use it again to create a different formatted string to use it.
Comments
Post a Comment