It’s a good trick. From windows 2000, when a MessageBox popped out, you can use Ctrl+C to copy the content of the MessageBox window to the clipboard. It is a very interesting trick, and it is very usrful to share the information easily.

The condition is only that the MessageBox window was created by MessageBoxA/MessageBoxW from the win32 api. Whether you call AfxMessageBox or CWnd::MessageBox in vc or MsgBox in vb, they finally call the ::MessageBoxA or ::MessageBoxW, so it also works.

Here is a example.

1. When some message box popped, press Ctrl+C to copy.

msgbox1.PNG

2. Paste in notepad, and you will see…

—————————
Notepad
—————————
The text in the Untitled file has changed.
Do you want to save the changes?
—————————
Yes No Cancel
—————————