Action on Error Message?

Hi,

Any tips on how to get KM to activate a macro when an Error Message suddenly appears.

For example, I've set up a looping macro in Premiere Pro which will tell the app to render my video files. Then after X minutes, escape and save, then re-start the render. The loops works great. But every once in a while, Premiere Pro itself crashes and this error message pops up:

So, what I'd like KM to do is stop the loop, [obviously], then force-quit the app > relaunch the app > and after X minutes, restart the loop.

But what I can't figure out is how to get KM to recognize the error message when it pops up, [it pops up on top of Premiere Pro]. And then, when KM 'sees' the error message, start the Force Quit and Restart macro, etc.

Any tips would be appreciated. Thanks.

FWIW, here's my macro for the render loop, [which works great].

Thanks,

Wayne