Im using keyboard hooks for some shortcuts that are application-wide and so far everything is working fine, but some short-cuts load non-modal forms and if a user presses a short-cut key while a MsgBox is up, the form loads and it looks kind of silly, or in some instances out right locks up the software.

Is there a way to determine (either through VB6 or an API) if a Messagebox, or any other dialog box is open so that I can ignore my hooks at that time?

Thank you,
Luke