0

I want to pass data from UICollectionViewCell when I selected to UITableView and displayed inside UITableView Inside the array

This is a images are for reference :

enter image description here

enter image description here

so I output the data to string

cell.foodName.text = foodnameout
cell.priceS.text = foodpriceout
cell.foodcounttext.text = foodcountout

println("\(cell.foodName.text):\(cell.foodcounttext.text)")
iAnurag
  • 9,286
  • 3
  • 31
  • 48
Ahmed R.
  • 1,209
  • 1
  • 12
  • 22
  • 2
    use singleton class for storing data and use it – Pravin Tate Jun 25 '15 at 12:28
  • Do you have an example of the work on it ? – Ahmed R. Jun 25 '15 at 12:33
  • 1
    No, don't use a singleton class. There are ways to pass data between objects without using singletons. There are many ways. The sooner novices start learning that, the better. – nhgrif Jun 25 '15 at 12:33
  • I'm voting to close this question as too broad. You give us no information about how the table view cell is related to the collection view cell (how to get from A to B). It's very, very unclear what you're asking. Even if you were to clarify it, this question would remain either too broad or a duplicate. I'm recommending you spend some time going through some pretty basic object-oriented programming tutorials and learn about how objects work. – nhgrif Jun 25 '15 at 12:37
  • @nhgrif can you please explain which are the many ways for that ? – Pravin Tate Jun 25 '15 at 12:40
  • @PravinTate http://stackoverflow.com/q/29734954/2792531 there's a start. – nhgrif Jun 25 '15 at 12:43
  • This is a duplicate of many other questions like this. Many ways to do this. – Race B Jun 25 '15 at 13:09
  • possible duplicate of [Passing Data between View Controllers](http://stackoverflow.com/questions/5210535/passing-data-between-view-controllers) – asjj Jun 25 '15 at 15:14

0 Answers0