Search
 
SCRIPT & CODE EXAMPLE
 

SWIFT

remove checkmark when selecting the cell again swift 5

 override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
        if let cell = tableView.cellForRow(at: indexPath as IndexPath) {
            if cell.accessoryType == .checkmark {
                cell.accessoryType = .none
            } else {
                cell.accessoryType = .checkmark
            }
        }
        tableView.deselectRow(at: indexPath, animated: true)
    }
Comment

PREVIOUS NEXT
Code Example
Swift :: random element from array swift 
Swift :: remove back button from navigation bar swift 
Swift :: Change BackgroundColor of Picker ios swift 
Swift :: Add UIToolBar to all keyboards 
Swift :: how to add social media icons in swiftui 
Swift :: swiftui delay 
Swift :: swipe left to go back iphone swift 
Swift :: swift bring something to front of view 
Swift :: round down swift 
Swift :: Return multiple value of different types swift 
Swift :: swiftui play mp3 
Swift :: how to get current shown collectionview cell index in swift 
Swift :: swift how to animate constraint change 
Swift :: swift do while 
Swift :: disable swipe to delete swift 
Swift :: swift tuple 
Swift :: swift uitableview insert cell 
Swift :: string value of enum swift 
Swift :: swift change label text 
Swift :: Swift Using insert() 
Swift :: swift multiline string 
Swift :: how to get the path of selected PDF/doc from file manager in ios swift programmatically 
Swift :: Swift Markup in Xcode 11 
Swift :: how to add corner in swiftui 
Swift :: swift create lazy property 
Swift :: Swift Expressions 
Swift :: swift apply changes after a word in string 
Swift :: while loops swift 
Swift :: data source in swift 
Swift :: 95 dollars in rupees 
ADD CONTENT
Topic
Content
Source link
Name
5+2 =