How to disable part of UISegmentedControl?

前端 未结 2 663
陌清茗
陌清茗 2021-02-03 17:37

Following is the code for UISegmentedControl

UISegmentedControl *segmentedControl = [[UISegmentedControl alloc] initWithItems:[NSArray arrayWithObje         


        
2条回答
  •  盖世英雄少女心
    2021-02-03 17:50

    For those who can be interested in the swift command:

    Swift 2.3

    segmentedControl.setEnabled(false , forSegmentAtIndex: 0);
    

    Swift 3

    self.segmentedControl.setEnabled(false, forSegmentAt: 0);
    

提交回复
热议问题