Top "Nsdate" questions

NSDate objects represent a single point in time.

How to add one month to an NSDate?

How To Add Month To NSDate Object? NSDate *someDate = [NSDate Date] + 30Days.....;

ios iphone objective-c nsdate
iPhone OS: How do I create an NSDate for a specific date?

Seems like a simple thing but I can't seem to find a way to do it. It would be great …

ios cocoa-touch nsdate nsdateformatter nscalendar
How do I get the current Date in short format in Swift

In the images below you can see the code I wrote and the values of all the variables: class fun …

swift date nsdate nsdateformatter dateformatter
converting timestamp to nsdate format

I want to convert my timestamp value 1308031456 to NSDate format (which yields the value Tue, 14 Jun 2011 06:04:16 GMT in online web …

objective-c iphone swift nsdate
Swift 3 - find number of calendar days between two dates

The way I did this in Swift 2.3 was: let currentDate = NSDate() let currentCalendar = NSCalendar.currentCalendar() var startDate : NSDate? var endDate : …

nsdate swift3 nscalendar
How can I get the current month as String?

I need to get may as a current month, but I could not do. How can I achieve this? let …

ios swift date nsdate nscalendar
NSDate beginning of day and end of day

-(NSDate *)beginningOfDay:(NSDate *)date { NSCalendar *cal = [NSCalendar currentCalendar]; NSDateComponents *components = [cal components:( NSMonthCalendarUnit | NSYearCalendarUnit | NSHourCalendarUnit | NSMinuteCalendarUnit | NSSecondCalendarUnit ) fromDate:date]; […

ios nsdate nsdatecomponents
Comparing NSDates without time component

In a swift playground, I have been using NSDate.date() But, this always appears with the time element appended. For …

ios time swift nsdate foundation
Difference between two NSDate objects -- Result also a NSDate

I have two NSDate objects and I want the difference between the two and the result should again be a …

iphone objective-c cocoa-touch ios nsdate
How to add hours to an NSDate?

I have a date converted to double value and saved in database. Now, I want to compare if currentDate > …

objective-c iphone-sdk-3.0 nsdate