Visual Basic - Otra vez ayuda, CAPSLOCK con API??

Life is soft - evento anual de software empresarial
 
Vista:

Otra vez ayuda, CAPSLOCK con API??

Publicado por Pablin (19 intervenciones) el 15/07/2005 19:58:45
Alguien sabe como simular el CAPSLOCK con API, este codigo que me pasaron ayer sirve para el NUMLOCK...

Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo As Long)

Public Sub SendNumLock()

Const KEYEVENTF_EXTENDEDKEY = &H1
Const KEYEVENTF_KEYUP = &H2
Const VK_NUMLOCK = &H90

keybd_event VK_NUMLOCK, vbKeyNumlock, KEYEVENTF_EXTENDEDKEY Or 0, 0
keybd_event VK_NUMLOCK, vbKeyNumlock, KEYEVENTF_EXTENDEDKEY Or KEYEVENTF_KEYUP, 0

End Sub

Pero no conseguí que funcione para el CAPSLOCK, alguien podria ayudarme por favor?, muchas gracias.
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder
sin imagen de perfil
Val: 14
Ha aumentado 1 puesto en Visual Basic (en relación al último mes)
Gráfica de Visual Basic

RE:Otra vez ayuda, CAPSLOCK con API??

Publicado por SuNcO (599 intervenciones) el 15/07/2005 21:14:03
Es facil encontrar eso en Google

Const VK_CAPSLOCK = &H14

Este no prende el foco del teclado, pero si funciona
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar