Can any one give me an idea how to get the current date in milliseconds?
There are several ways of doing this, although my personal favorite is:
CFAbsoluteTime timeInSeconds = CFAbsoluteTimeGetCurrent();
You can read more about this method here. You can also create a NSDate object and get time by calling timeIntervalSince1970 which returns the seconds since 1/1/1970:
NSTimeInterval timeInSeconds = [[NSDate date] timeIntervalSince1970];
And in Swift:
let timeInSeconds: TimeInterval = Date().timeIntervalSince1970