Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Messagebox API
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
Divers
Thread ID:
00475884
Message ID:
00476328
Vues:
43
>>>>WM_HELP, is sent if ON('KEY', 'F1') = 'HELP'. If it's own error dialogs, then VFP wouldn't necessarily be using WM_HELP. I can't find what message VFP sends to activate it's help, but pressing F1 does generate a WM_HELP message that VFP processes if no dialog is present.
>>>
>>>I couldn't get VFP to do this. Were you looking at the main window or one of VFP's child windows (or one of its extraneous windows)?
>>
>>Sorry, I missed this. I wasn't looking at the window. I was looking at the process.
>
>Okay, now I get it. I finally saw what you saw using a different time and space orientation. :-)

A rip in the space/time continuum?:-)

>The problem seems to be that MessageBoxEx sends its WM_HELP message to the owner window, not the owner thread/process. The VFP main window's WinProc does not know what to do with that message. You would have to write something to hook into the WinProc (VB or VC++) and pass that along to the thread in order to get the behavior of bringing up the help.

In my tests, it did seem to show up in the calling process, and the same behavior occurred when you normally (no dialog) pressed F1. Of course, I may have been looking at the wrong thing or different things, but I don't think I did. Wouldn't be the first (and probably not the last) time that I futzed up a test like this.

As I mentioned to Neil, what I'm guessing is that VFP's been set up to respond to the WM_HELP message only when it's the active window and/or has the keyboard focus. If it doesn't it may be ignoring the message. Given what I've seen, it's the only possible explanation I can come up with. Of course, if I screwed up the tests, this theory may be invalid as well, and your's might be the right answer.

In the latter case, it might very well be possible to call help from MessageBoxEx(). The problem there is finding the right hWnd.

>Thanks for sticking with me George!

And thanks for sticking with me, Larry.< s >
George

Ubi caritas et amor, deus ibi est
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform