Unfortunately unless you catch them in the act, there's nothing you can do. Just keep alot of Natures Miracle on hand.

My foster has occasional accidents so I have keep a very close eye on him and when he shows signs of getting ready to go I promptly make a very loud noise to stop him then put him outside.