Did you brign her home recently? She may just be adjusting to a new place. Either way, she needs a brush up on her potty training so you need to keep her supervised so you can catch her when she starts sniffing for a spot to go. You must catch it before it happens or during and then bring her outside.

Showing it to her after she's done it will only make her think you are yelling at her for no reason. A dog can't learn to trust a person if they are sleeping in another room and all the sudden the human comes in yelling and drags them into a different room to point at something. All the dog knows is it was sleeping and not provoking anything and you "attacked" it. That means the dog can't trust you for a second and always has to be on the look out for one of your unprovoked attacks.