Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

288
Visualizações
How to animate particular table View cell

I have a table view that has 4 cells. And I want to hide first two cell for few second And i am doing this -:

   func tableView(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) {
    if historyArray.count > 0 {
        cell.alpha = 0
        if indexPath.row == 0 || indexPath.row == 1 {
        UIView.animate(
            withDuration: 1,
            delay: 0.05 * Double(indexPath.row),
            animations: {
                cell.alpha = 1
        })
    }
    }

but this code has not worked for me. how to do this.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

can u pls try this

func tableView(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) {
        
        if indexPath.row == 0 || indexPath.row == 1 {
            cell.transform = CGAffineTransform(translationX: self.view.frame.width, y: 0)
            UIView.animate(withDuration: 1) {
                cell.transform = .identity
            }
        }
    }
over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda