This guide is specific to Mojave(10.14.3). Applications in any other operating systems may vary.
If you are having trouble allowing access to your Mac on TeamViewer please follow this guide.
1. On your desktop press on the Apple symbol on the top left:
2. Then click on System Preferences:
3. Click on the security and privacy icon:
4. Click on the Privacy tab and then the Accessibility option:
5. You may need to click on the lock icon on the bottom left and fill in your login details in order to make changes.
6. Check the box next to TeamViewer: