I searched for a long while on articles about how to herd the goats. everyone was just saying you should chase them into the barn. yeah ok, but my goats weren't going in!
What you have to do, is approach the farm owner while you are ON the horse to start the actual herding game. If you jump off the horse and approach him, the game doesn't start.
You will be given an option to help after the dialogue (if you are on the horse) and just click yes, then the music kicks in.
If you chase the goats to the barn, they go right in.
If you jump off the horse when you enter the farm, and walk up to the guy, the same dialogue does not happen. If you go back to the horse and get on, then start herding, they will NEVER go in!