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

404
Visualizações
How to fix this error ' this class is not key value coding-compliant for the key containerView.'?

When the user what to sign up or login it has error and get this error in the output "this class is not key value coding-compliant for the key containerView." this is the login code also signup has the same error and l'm sure it's a right codes.

import UIKit
import Firebase

class LoginViewController: UIViewController {

  @IBOutlet var Aemeil: UITextField!
  @IBOutlet var Apassword: UITextField!

  override func viewDidLoad() {
      super.viewDidLoad()
  }

  @IBAction func login (_ sender : Any){

      guard let email = Aemeil.text, let password = Apassword.text
        else {
            print("Form is not valid")
            return
      }

      Auth.auth().signIn(withEmail: email , password: password , completion: { (user,error) in
        if error == nil{
            let vc = self.storyboard?.instantiateViewController(withIdentifier: "AHome");
            self.present(vc!, animated: true, completion: nil);
            print("Home page open")
        }
        else{
            let alertController = UIAlertController(title: "Error", message: error?.localizedDescription, preferredStyle: .alert)
            let defaultAction = UIAlertAction(title: "Yes", style: .cancel, handler: nil)

            alertController.addAction(defaultAction)
            self.present(alertController, animated: true, completion: nil)
        }         

    })
  }
}
over 4 years ago · Santiago Trujillo
2 Respostas
Responde à pergunta

0

You have created a binding from a storyboard element, to an element in the corresponding swift file, with the name containerView. After that you have deleted the containerView variable in your swift file, but the binding still exists in the storyboard.

To solve this problem go to your storyboard, click on the view controller, like below:

inspector2

After that, click on the connection inspector, to see all bindings of your viewcontroller and delete the binding from the containerView:

inspector1

over 4 years ago · Santiago Trujillo Relatório

0

I have faced the similar problem, I created a segmentview under which I've kept a containerView and removed the default segue that came along with that container view. After that I renamed the container view controller name and connected as show segue. This was the problem which caused me to face this issue. When I changed the show segue to Embed segue the problem resolved.

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