Get iPhone OS version

Discussion in 'iOS Programming' started by Svinja, May 20, 2009.

  1. Svinja macrumors newbie

    Joined:
    Oct 27, 2008
    #1
    Hi,
    is it possible to detect OS version currently running on Iphone in code?

    I have a problem which works fine with 2.2.1 version but it doesnt with 3.0(Status bar bug fixed). I need to compile application on 2.2.1 so it can work both on OS 2.2 and 3.0. Thx for your help!
     
  2. Svinja thread starter macrumors newbie

    Joined:
    Oct 27, 2008
    #3
    Thank you! Didnt know UIDevice exists...
    solution is:
    float version = [[[UIDevice currentDevice] systemVersion] floatValue];
     

Share This Page