ID Number: Q69896
3.00
WINDOWS
docerr
Summary:
SYMPTOMS
The sample code to access an alternate keyword table in a Windows
Help file from an application, provided on page 18-21 in the
"Microsoft Windows Software Development Kit Tools" manual for
version 3.0 is incorrect.
STATUS/RESOLUTION
Microsoft has confirmed that this documentation error occurs on
page 18-21 in the "Microsoft Windows Software Development Kit Tools"
manual for version 3.0. This error has been corrected on Page
42 of the "Microsoft Windows Software Development Kit Tools" manual
for version 3.1. A different example is included on Page 42.
The following is the correct code to access the 'B' keyword table
in a Windows Help file:
HANDLE hmk;
MULTIKEYHELP far *pmk;
char szKeyword[] = "B-keyword";
case MULTIKEY:
hmk = GlobalAlloc(GHND, (sizeof(MULTIKEYHELP)+lstrlen(szKeyword)));
if (hmk == NULL)
break;
pmk = (MULTIKEYHELP FAR *)GlobalLock(hmk);
pmk -> mkSize = sizeof(MULTIKEYHELP)+lstrlen(szKeyword);
pmk -> mkKeylist = 'B';
lstrcpy(pmk -> szKeyphrase, szKeyword);
WinHelp(hWnd, szHelpFileName, HELP_MULTIKEY, (DWORD)(LPSTR)pmk);
GlobalUnlock(hmk);
GlobalFree(hmk);
break;
Additional reference words: 3.00 docerr MICS3 T18