交换机如何在XCode4中运行?如何检查交换机可用的属性? 我试图检查一个开关的状态,并根据状态更改标签。像这样:
-(IBAction)clickedOnSwitch:(id)sender {
NSString *switchState = [[NSString alloc]init];
if (mySwitchIsOn) {
switchState = @"switch is On";
}
else
{
switchState = @"switch is Off";
}
myLabel.text = switchState;
[switchState release];
}