Here a great link with lots of good information, you're right never punish your dog for making a mistake. Remember. it's never their mistake, it's yours, you haven't done something right. Also most yorkies aren't completely trained till much later. I think the average age is 8 months. You just can't give them in opportunity to make a mistake, and they will catch on faster.
Free House Training for Puppies and Adult Dogs - No More Accidents Starting Today!