I'm creating my own DialogBox. How can I make this DialogBox always appear to the top right corner of my MainWindow? I mean the dialog box should move with the MainWindow like a conjoined twins.
Thx in advance.
I'm creating my own DialogBox. How can I make this DialogBox always appear to the top right corner of my MainWindow? I mean the dialog box should move with the MainWindow like a conjoined twins.
Thx in advance.
You can use code from this answer to help you achieve your goal: How to set the location of a WPF window?
When you create a MyDialogBox, get the location of the current / main window and use that to help calculate where you should set the location of your MyDialogBox