UISwitch On/Off 상태 가져오기




UISwitch* whatSwitch = [[UISwitch alloc] init~~];
...
if (whatSwitch.on == YES) { 
      //Do stuff 
} 
else if (whatSwitch.on == NO) { 
      // Do other stuff 
} 
else { 
      // Do stuff if whatSwitch is nil 
}