lunes, 18 de diciembre de 2017

iOS: Show message / show alert

private func showAlert(withMessage message: String) {
        let alertController = UIAlertController(title: title, message: message, preferredStyle: UIAlertControllerStyle.alert)
        alertController.addAction(UIAlertAction(title: "Ok", style: UIAlertActionStyle.default) { alertAction in
           
            alertController.dismiss(animated: true, completion: nil)
        })
       
        self.present(alertController, animated: true, completion: nil)
    }

No hay comentarios:

Publicar un comentario