According to the MS Site, getkeyboardstate is in user32.dll, not
kernel32.dll. I'm not in a postition to check who's right, at the
moment...
Stephen Gray wrote:
>
> Hi all,
>
> I'm trying to use the Call Library Function VI to call GetKeyboardState
> from kernel32.dll as suggested below. I put the VI on my diagram and
> right click to configure. Then I pick the dll from the
> c:\windows\system directory. It gives me a list of functions in the dll
> to choose from but GetKeyboardState is not one of them. I'm using
> Windows95 and the version of kernel32.dll is version: 4.03.1212. Do I
> have an old version of the dll?
>
> Has anyone had success using this function call from this dll? Also, if
> this is a result of an older version of the dll, is it possible to just
> copy the dll from a Windows98 box? Will that screw other things up?
>
> Thanks,
> stephen
>
> >Hi,
> >
> >You could use de windows dll GetKeyboardState (kernel32.dll) to monitor
> if
> >ALT+key is pressed. It is not ideal, because it requires a while loop
> to
> >call this dll all the time. If a key, mouse button, or combination, is
> >pressed, you can trigger a boolean, or whatever you want.
> >
> >To call the dll, use a numeric 8 bit as output, stdcall(WINAPI) as
> calling
> >convention and a 8 bit array as first (and only) argument (with Array
> Data
> >Pointer as Array Format). Wire a 8 bit array to argument1, filled with
> 256
> >dummy values. If a value is pressed, the corresponding array element
> changes
> >to 128.
> >
> >Regards,
> >
> >Wiebe Walstra.
> >
> >--
> >AIR technical Automation
> >www.air.nl
> >"Stephen Gray"
wrote in message
> >news:39F735F4.2BD9EA8A@swri.org...
> >Does anyone know of a way that I can attach the keyboard sequence
> >F10 to a control in Labview. I've used the key navigation
> >successfully to make use of the Control and shift modifiers, but I
> >REALLY need to use the modifier. Anyone know of a work around?
> >BTW - I'm using Labview 6i under Windows95.
> >
> >Thanks,
> >Stephen