Search code examples
iphonenscalendarnstimezone

NSTimeZone difference to GMT


I need to get the information of the difference between users timezone, to GMT London time, in hours, or minutes.

Anyone can help?

I've been looking around and i'm kind of confused.

Thanks,

rui


Solution

  • NSTimeZone has a method called secondsFromGMT.

    Return Value
    The current difference in seconds between the receiver and Greenwich Mean Time.