How can I compare two different dates to find out which is the later date? For example, in date1
I will store one date after downloading some data, and in date2
, I will store the current date. Then I need to check which one is greater/later: something like if(date1>date2)
.
相关问题
- CALayer - backgroundColor flipped?
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- State preservation and restoration strategies with
- “Zero out” sensitive String data in Swift
相关文章
- 现在使用swift开发ios应用好还是swift?
- UITableView dragging distance with UIRefreshContro
- TCC __TCCAccessRequest_block_invoke
- Where does a host app handle NSExtensionContext#co
- xcode 4 garbage collection removed?
- Xcode: Is there a way to change line spacing (UI L
- Unable to process app at this time due to a genera
- Swift - hide pickerView after value selected
This is what I used for comparing dates with timezones, and worked for me using iOS 6
Something like:
you can use NSDate's compare: method: