Guest User

Untitled

a guest
May 20th, 2018
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.75 KB | None | 0 0
  1. //MARK: UI
  2. extension ChooseImageViewController{
  3. func showError(errorMessage : String){
  4. let alertController = UIAlertController(title: "Error", message: errorMessage, preferredStyle: .alert)
  5. let action = UIAlertAction(title: "dismiss", style: .default)
  6. alertController.addAction(action)
  7. self.present(alertController, animated: true, completion: nil)
  8. }
  9.  
  10. func showResultScreen(image : UIImage,resultString : String){
  11. let vc = UIStoryboard(name: "Main", bundle: Bundle.main).instantiateViewController(withIdentifier: "ResultViewController") as! ResultViewController
  12. vc.image = image
  13. vc.resultString = resultString
  14. self.navigationController?.pushViewController(vc, animated: true)
  15. }
  16. }
Add Comment
Please, Sign In to add comment