The reason your dog’s whining is to get your attention, giving your dog attention enforces that whining gets them what they want. So you can Ignore them. At first, you leaving will only make the whining get louder. In other words, it’s going to be torture for you, but if you want this behavior stopped, you need to power through. After a while, your dog will learn that whining doesn’t work and resort to other attention-getting tactics.
Resist yelling. In fact, if your dog’s whining is caused by anxiety, yelling will only increase the amount of whining. Honestly, yelling at your dog is never the solution; so, resist the urge as much as humanly possible.
Praise calm behavior or Get your dog to sit
Hopefully, these tactics will be less annoying!