All working. Just need to clean up the code.