Saludos a todos :
Antonio :
Hay forma alguna de accesar a una toolbar y su contenido usando el Tabulador.?
Vikthor
Saludos a todos :
Antonio :
Hay forma alguna de accesar a una toolbar y su contenido usando el Tabulador.?
Viktor,
Prueba a usar el estilo WS_TABSTOP al crearla. Modifica la clase.
Antonio Linares wrote:Viktor,
Prueba a usar el estilo WS_TABSTOP al crearla. Modifica la clase.
TB_MAPACCELERATOR
wParam = (WPARAM)(TCHAR) chAccel;
lParam = (LPARAM)(LPUINT) pIDBtn;
Maps an accelerator character to a toolbar button.
Returns nonzero if successful, or zero otherwise.
chAccel
Accelerator character to be mapped. This character is the same character that is underlined in the button's text.
pIDBtn
Address of a UINT that receives the command identifier of the button that corresponds to the accelerator specified in cchAccel.lResult = SendMessage( // returns LRESULT in lResult
(HWND) hWndControl, // handle to destination control
(UINT) TB_MAPACCELERATOR, // message ID
(WPARAM) wParam, // = (WPARAM) (TCHAR) chAccel;
(LPARAM) lParam // = (LPARAM) (LPUINT) pIDBtn;
);#define TB_MAPACCELERATOR 1102
METHOD AccButton( nVirtKey , nButton ) CLASS TToolBar // Vikthor
SendMessage( ::hWnd , TB_MAPACCELERATOR , nVirtKey , nButton - 1 )
return nil oToolBar:AccButton( Asc( "N" ) , 1 )Algún tip o sugerencia
![]()
Vikthor,
El ultimo parámetro parece distinto a como lo has declarado:
>
pIDBtn
[out] Pointer to a UINT. On return, if successful, this parameter will hold the id of the button that has chAccel as its accelerator character.
>
Ha de ser el puntero a un número, y contendrá el valor del botón, no el número en si.
El mensaje es para preguntar un valor, no para asignarlo