LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Trapping <ALT>F10

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
0 Kudos
Message 1 of 6
(2,809 Views)
There is a library to get keystrokes on zone.ni.com. To find it search "Keyboard
Utilities for Capturing Keystrokes", this gets you all the keys. I think
the problem with using alt is that it is used to access the file, edit, help,
etc. menus at the top of the window and that may be why you have trouble
using it for something else. Hope this helps.

Stephen Gray wrote:
>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>
0 Kudos
Message 2 of 6
(2,809 Views)
[posted and mailed]

sgray@swri.org (Stephen Gray) wrote in <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.
>

There doesn't appear to be one in any of the versions so far. This is
because the Alt key refers to the runtime menu of the executing program, As
a workaround you could use alt and any other letter and refer to this via a
runtime menu - this might work okay but I agree that it is pretty clunky.

cheers, Alex.

--

Alexander C. Le Dain, PhD
ICON Technologies Pty Ltd
ht
tp://www.icon-tech.com.au
0 Kudos
Message 3 of 6
(2,809 Views)
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 tha
t 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
0 Kudos
Message 4 of 6
(2,809 Views)
In article <39F735F4.2BD9EA8A@swri.org>,
Stephen Gray wrote:
> 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.

Out of curiosity, are you by any chance writing a :CueCat interface for
LabVIEW? (ie. the free bar code scanners at RadioShack and
http://www.getcat.com/ , which spit out F10 and then an encoded
version of the barcode when you scan something)

It's probably just a coincidence though...


Sent via Deja.com http://www.deja.com/
Before you buy.
0 Kudos
Message 5 of 6
(2,809 Views)
I've been working in the interface for the Cue Cat, but I haven't been
able to decode data... any suggestions...

Paul


In article <8tj8kt$un9$1@nnrp1.deja.com>,
bk1e@my-deja.com wrote:
> In article <39F735F4.2BD9EA8A@swri.org>,
> Stephen Gray wrote:
> > 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.
>
> Out of curiosity, are you by any chance writing a :CueCat interface
for
> LabVIEW? (ie. the free bar code scanners at RadioShack and
> http://www.
getcat.com/ , which spit out F10 and then an encoded
> version of the barcode when you scan something)
>
> It's probably just a coincidence though...
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>


Sent via Deja.com http://www.deja.com/
Before you buy.
0 Kudos
Message 6 of 6
(2,809 Views)