Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Amit Jain

macrumors member
Original poster
Apr 9, 2007
45
0
Hi All,

Actaully what I need is ..
Suppose I have 4 rows and each has a switch which are sharing a same action method as they are added at runtime. (Ex: a multiple choice question with 4 options).
Now what I want is if user selects any switch suppose he selects option A...then action method willbe called and I will come to know the state of the switch(ON/OFF) but how I will come top know that which row (or option A/B/C/D) is being selected as the action for all the switches is same.
I know one very basic answer will be "make 4 actions for each switch". But only want to use single action method.
I think now its slear what I need.
p.s. sorry for so long question .;)
 
I think there is an Apple example called TouchCells or something like that, which I believe sets up a table view with switches in each cell. It might be worth having a look at that since I think it does something similar to what you want to do.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.