iPhone: Issue comparing a date between current date and sixty days from current date
问题 I need to check an event date, which should be between Current date and 60 days from now. The below code is used, but it is NOT working correctly. Please note, i'm getting event string like this - "2012-04-14T16:50:02Z" from my server. // current date double currDateInMilliSecs = [NSDate timeIntervalSinceReferenceDate] * 1000; NSLog(@"currDateInMilliSecs: %f", currDateInMilliSecs); // sixty days double sixtydaysvalue = 60.0 * 24.0 * 3600.0 * 1000.0; NSLog(@"sixtydaysvalue: %f", sixtydaysvalue