objective c - Get exactly 1 day using NSDate -


I How can a day before using NSDate i.e. 2014-08-01 00:00:00 +0000 of 2014-08-01 23:59:59 +0000 Is it possible to use Ansdit?

I do not clearly understand your question. If you to get the next day for NSDate are:

  + (Ansditi *) Nanbrofde: (Ansaitiafr) Nanbrof D: to: date (Ansdit *) {NSDATConnector * DayCompany = [[NSDATCompanies Eloop] Init]; DayComponent.day = numberOfDays; NSCalendar * Calendar = [NSCalendar Current Calendar]; Return [calendar dated date banking companies: day to date: Sedet options: 0]; }  

If you want to compare the two, two-day Ansdite the same day, then (Ansditi category):

 < Code> - (BOOL) is onsmadeae :: (NSDT *) Date {NSC calendar * Calendar = [NSC calendar carrier]; NSDateComponents * components1 = [calendar components: (NSYearCalendarUnit | NSMonthCalendarUnit | NSDayCalendarUnit | NSWeekCalendarUnit | NSHourCalendarUnit | NSMinuteCalendarUnit | NSSecondCalendarUnit | NSWeekdayCalendarUnit | NSWeekdayOrdinalCalendarUnit] date: self]; NSDateComponents * components2 = [calendar component: NSYearCalendarUnit | NSMonthCalendarUnit | NSDayCalendarUnit | NSWeekCalendarUnit | Ansacoar Kailnderyuenaiti | NSMinuteCalendarUnit | Anssicondkalendryuenaiti | Ansdbluiikedalenderaunit | NSWeekdayOrdinalCalendarUnit date: date]; return ((components1.year == components 2kyuar) & amp; amp; amp; (component 1 month == components 2 months) & amp; Amp; (components 1. D Neither == components 2nd day));}  

Comments

Popular posts from this blog

Member with no value in F# -

java - Joda Time Interval Not returning what I expect -

c# - Showing a SelectedItem's Property -