Well I managed to work around by putting a custom UIButton
on UITableCellView
and firing off the required methods on UIControlEventTouchUpInside
. This ate my brains for 2 days!!
UiTextView in Custom UiTableViewCell does not responds to didSelectRowAtIndexPath
-
30-05-2022 - |
Question
I have a UITextView
on a custom UITableViewCell
and when I click on the UITextView
, it does not trigger the didSelectRowAtIndexPath
, how do I change this behavior so that that delegate is called as intended?
Ive tried putting the User enabled property of UITextView
to false. When doing so it responds to the didSelect. But then Im not able to select the links that are mentioned in the TextView, which essentially is the main reason why i chose to go ahead with UITextView
.
Any help or pointer guys
La solution 3
Autres conseils
you can't do both the things at same time.
you can use UITableViewCell *cell = [tableView cellForRowAtIndexPath:indexPath]
in you didselectrowatindexpath method.
you need to give appropriate tag to every text field and by using [cell viewWithTag:<#(NSInteger)#>]
you can get the text-field object and link which are mentioned in it .
If your table view is custom, you can fire didSelectRowAtIndexPath event yourself when the user touch the text view.