I need to refresh a view controller when a certain button is tapped. Simply activating viewDidLoad() does not seem to be working for what I need to
view controller
viewDidLoad()
Whatever code you are writing in viewDidLoad, Add that in viewWillappear(). This will solve your problem.
viewDidLoad
viewWillappear()
If you are using a navigation controller you can segue again to the current UIViewController and it will be refreshed.