Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Accepting ? output in a window/form
Message
De
03/09/1999 17:38:17
 
 
À
03/09/1999 17:12:32
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00261395
Message ID:
00261409
Vues:
17
>I have a question about how VFP determines whether a given window can accept output from the VFP ? command.
>
>Here is a sample scenario:
>
>1. Run an APP which opens a modeless form.
>
>2. Go to the command window, do '? 222'. '222' appears in the form, messing it up to high heaven.
>
>3. Type 'ACTIVATE SCREEN' in command window, then '? 222'. '222' now appears on the VFP screen.
>
>4. Bring the APP form to the front.
>
>5. Go back to the command window and '? 333'. '333' appears in the form again.
>
>Okay, so you figure that you just need an 'ACTIVATE SCREEN' in your APP form's DEACTIVATE method. But...
>
>6. Open a window with MODI COMM FOO
>
>7. Go back to the command window, and the old APP form is still receiving the outpout of '? 333'.
>
>Now, clearly, VFP knows that the MODI COMM window should not receive the output of the ? command, so it's bypassing that window to put output in the fom app's window, even though it's not the currently active window.
>
>Is there some way to make VFP know not to send ? output to the form window?
>
>-- jas


By default, the currently active window receives the output. Once you do something that brings up some other window, then close that other window, the output will now be directed to the previous window. The desktop (ACTIVATE SCREEN) can only be set to receive output with ACTIVATE SCREEN. Once it loses focus, it does NOT automatically receive it back. That goes to any other window (your form) that happens to be open.

So if you go to the command window and type ACTIVATE SCREEN and then some ? statements, the output goes to the desktop. If some other form pops-up because of an error or something, the output will now return to your form. You must reissue ACTIVATE SCREEN to get the output to go there again. That's the way it is.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform