Hi,
if you raise an Error type of message, the execution is stopped. You either need to display the message before opening the window, or if you want to display the window, display another kind of message (Warning for example), and put a Close Window action afterwards.
_________________________
~soba