Let's me get this right. You are saying that when you are in the VFP development environment, you do Alt+W+D to open the data session window. When you are in the debugger, you do those same keystrokes, thinking you are going to open the data session window, but in fact you do a Cascade instead.
Have I got that right?
If so, my first reaction would be to stop using that particular key combo. There are plenty of other ways of opening the data session window. Get out of the habit of using those keys, and the problem will go away.
If that's not acceptable, how about recording a simple keystroke macro: Alt+W, followed by three Downs. If you run that in the debugger, it will restore the windows to their default state. If you accidentally run the same macro in the main development window, it will hide the window you just opened, which might be what you want.
Or have I compeltely misunderstood the problem?
Mike
__________________________________
Mike Lewis (Edinburgh, Scotland)
My Visual FoxPro site: www.ml-consult.co.uk