How do I find out whether the active window is a dialog form or something else?

Please help --- I am new to VB.

Bye and thanks (in advance)