I have TC v17 on windows7, running a .btm in TCC tab, using a popup Msg box with 4 custom buttons for user to select. After selection, sometimes this window closes, sometimes not. An OKcancel 2 button Msg box for example always seems to close.
I have the auto attach consoles (I believe this is the terminology used) selected from the main TCC options menu, yes nothing to do with msgbox command.
The .btm, for example, has 2 successive msgbox commands:
msgbox /1"Pc 1" /2"Pc 2" /3"Pc 3" /4"Pc 4" "Part Inspection" Select the part type
(logic to set %pick equal to button label)
msgbox OKCancel "Part Inspection" %pick selected
The first 4 button pop window does not always close.
I tried your example 50 times and never saw the first msgbox fail to close.
Looking at the code, the only ways I can see for the close to fail is (1) a Windows API failure (unlikely), or (2) another app (like a screen manager) hooking the msgbox call (and failing to close). Given that MSGBOX is heavily used & this is the first report I've ever seen about it failing to close, I suspect there's a conflict with something else on your system.
WAD - they're not the same icon type. The first one is MB_ICONINFORMATION, the second is MB_ICONQUESTION. Windows has different default sounds for them. (TCC doesn't have anything to do with the sound, that's done by Windows.)