I have a tale which is containing a custom view interface. Here is customeview class definition.
@interface CustomTableCellview : UITableViewCell {
UILabel *titleOfPost;
UILabel *userProfileName;
UIImageView* profileImage;
UILabel *countOfFave;
}
@property(nonatomic,retain) IBOutlet UIImageView *profileImage;
@property(nonatomic,retain) IBOutlet UILabel *titleOfPost;
@property(nonatomic,retain) IBOutlet UILabel *countOfFave;
@property(nonatomic,retain) IBOutlet UILabel *userProfileName;
These all values are showing in my table. I want to call a function whenever user will click either ON/OFF button. Here is my tableview class definition.
@interface VIPsScreen : UITableViewController {
NSMutableArray* tableList;
IBOutlet CustomVIPCell *tblCell;
NSMutableArray* chengdArray;
}
I want to store all related “userProfileName” in array “chengdArray” which has UISWitch values “ON”. How will I resolve this problem.
Thanks in advance
Use
where you’re initializing instances of UISwitch and
as a callback method where you should check with one was switched and take actions…