BBC BASIC for Windows
Programming >> BBC BASIC language >> Using the WM_HELP command
http://bb4w.conforums.com/index.cgi?board=language&action=display&num=1395338306

Using the WM_HELP command
Post by kingsmiller on Mar 20th, 2014, 5:58pm

Does any Developer have an Example Program, snippet of Code and/or advise on using the WM_HELP command.

I have seen Applications where top right - next to the Close Button on a Dialogue Box is a “?” symbol. This when you click and reposition next to a static (for example) and re-click it would open up a "MessageBox" - which gave Information to the User.

Been working on this project on and off for a few weeks now and only having limited success, up to now I don’t have anything I can publish here.

I do understand that I need to use ..

1 - WINLIB2B
2 - *SYS 1
3 - and that the value of WM_HELP is 83 (via @msg% ) when you need to test which key is pressed.
4 - dlg%!16=&90C820C4 is needed to produce the "?"

I have searched BB4W Wiki , Help Topics, Example Programs and the Manual and the only reference I can find is this below (from “Help Topics”), which due to my amateur status does not mean much to me. A short Example Program would really be a great help.


“BBC BASIC for Windows version 5.94a or later only)
The @wparam% value of the WM_HELP message contains the context type in the LS 16-bits (LOWORD) and the control's ID in the MS 16-bits (HIWORD). This makes it possible to determine the control's ID even when the parameter block pointed to by @lparam% is no longer valid.”


Many Thanks

Re: Using the WM_HELP command
Post by rtr on Mar 20th, 2014, 11:53pm

on Mar 20th, 2014, 5:58pm, kingsmiller wrote:
A short Example Program would really be a great help.

It's far from short (!) but FIRBBC, which is Open Source, uses that style of context-sensitive help:

http://sourceforge.net/projects/firbbc/

But I don't advise adopting it in your own programs because it has effectively been deprecated by Microsoft. In Windows Vista and later they removed all the context-sensitive help from the Common Dialogues, which results in the rather silly situation that in BB4W - and no doubt many other applications - the 'custom' dialogues (for example Options... Set Font) do have it but the 'common' dialogues (for example File... Load) don't.

So, although still supported by the Windows API, context-sensitive help in dialogue boxes can be considered obsolete.

Richard.
Re: Using the WM_HELP command
Post by kingsmiller on Mar 21st, 2014, 07:40am


Many Thanks for your quick reply.

Once again Richard thank you for your great technical support.

I appreciate your advice and will not pursue context-sensitive help in dialogue boxes.

Regards .. Bill