WMessageBox is a convenience class for simple modal
dialog boxes. They contain a line of text (the message) and a
number of buttons.
With respect to programming style, the first and the third example
use a local event loop, the second and the last button don't. The
difference is invisible; it is usually better not to use a local
event loop.