Olly
May 1st, 2001, 09:16 AM
Does someone know how to use the LoadAccelerators function?
My code looks like that:
Dim vAccel As ACCEL
vAccel.cmd = GetMenuItemID(GetSystemMenu(frmMain.hwnd, 0&), 8)
vAccel.fVirt = FSHIFT
vAccel.key = Asc("Y")
CreateAcceleratorTable vAccel, 1
'and now that odd part:
LoadAccelerators ????????
the msdn library says:
LoadAccelerators
The LoadAccelerators function loads the specified accelerator table.
HACCEL LoadAccelerators(
HINSTANCE hInstance, // handle to application instance
LPCTSTR lpTableName // address of table-name string
);
Parameters
hInstance
Handle to an instance of the module whose executable file contains the accelerator table to load.
lpTableName
Pointer to a null-terminated string that names the accelerator table to load. Alternatively, this parameter can specify the resource identifier of an accelerator-table resource in the low-order word and zero in the high-order word. The MAKEINTRESOURCE macro can be used to create this value.
I absolutely don't have any clue about what the author meant by this explanation :confused:
My code looks like that:
Dim vAccel As ACCEL
vAccel.cmd = GetMenuItemID(GetSystemMenu(frmMain.hwnd, 0&), 8)
vAccel.fVirt = FSHIFT
vAccel.key = Asc("Y")
CreateAcceleratorTable vAccel, 1
'and now that odd part:
LoadAccelerators ????????
the msdn library says:
LoadAccelerators
The LoadAccelerators function loads the specified accelerator table.
HACCEL LoadAccelerators(
HINSTANCE hInstance, // handle to application instance
LPCTSTR lpTableName // address of table-name string
);
Parameters
hInstance
Handle to an instance of the module whose executable file contains the accelerator table to load.
lpTableName
Pointer to a null-terminated string that names the accelerator table to load. Alternatively, this parameter can specify the resource identifier of an accelerator-table resource in the low-order word and zero in the high-order word. The MAKEINTRESOURCE macro can be used to create this value.
I absolutely don't have any clue about what the author meant by this explanation :confused: