I have three tables in a view, I need to implement this kind of structure;
I need to control if the row is selected in the first table, then adding rows of the third table to other view. when i press the button, the data of the selected and the rows in the third table added to view will be sent.
Firstly, i am unable to recognize whether the row is selected or not,
Secondly, when i try just to check it works, my data dictionary sent is empty, that should not.
My code is as below;
-(void) shareComment : (id)sender
{
int ndx = [[tableViewPharmName indexPathForSelectedRow] row];
ProdForLiterature *temp = [pharmsTable objectAtIndex:ndx];
[sendData setObject:temp.productID forKey:@"ProductName"];
[sendData setObject:temp.productName forKey:@"ProductId"];
NSMutableArray *customerId = [[NSMutableArray alloc]init];
for(DoctorListCell *cell in tableViewDoctorName.visibleCells)
{
if([cell.plusButton isHidden])
{
if(cell.customerId!=nil)
{
[customerId addObject:cell.customerId];
}
}
}
[sendData setObject:customerId forKey:@"CustomerId"];
}