-2
도와주세요. 3 NSArray
: arr1, arr2, arr3
입니다.SegmentedControl NSArray를 변경
- (void)viewDidLoad
{
///arr1
///arr2
///arr3
for(NSString *name in arr1)
{
///mycode
}
}
- (IBAction)didChangeSegmentControl
{
if (self.switchSegmented.selectedSegmentIndex == 0)
{
NSLog(@"arr1");
}
else if (self.switchSegmented.selectedSegmentIndex == 1)
{
NSLog(@"arr2");
}
else if (self.switchSegmented.selectedSegmentIndex == 2)
{
NSLog(@"arr3");
}
}
내
segmentedControl
이
selectedSegmend2
때
가 어떻게 내 arr1
arr2
으로이 CHAGE 수 ???
이 라인을 for(NSString *name in arr1)
으로 변경하려면 for(NSString *name in arr2)
과 segmentedControl
이 selectedSegment 2
인 경우를 변경하고 싶습니다.
고마워요.