How to operate button in popup window dialog

How to click button in popup window dialog, like following screen shot

If that is a JavaScript alert, you can use these keywords

ok. Thank you for you information. Currently I try following method. And it works.
Robot robot = new Robot()

I will use you suggestion in later test scenario.