LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

In Program CVICALLBACK function calls

Hi

I have a number of button controls on by program which call various
CVICALLBACK functions. I would now like to sequence these calls
automatically. So is possible to simulate a button press, so that when
one procedure completes succesfully the next one in the sequence starts
up. I've tried using using QueueUserEvent but this doesn't seem to do
what I want. I don't want to call the procedure directly as I'll load
the stack with uncompleted procedure calls!!


--
Brian Laffoley
Hardware Development Engineer
(Yes - I know you shouldn't get a hardware engineer developing software
- but needs must when the devil drives!!)
0 Kudos
Message 1 of 3
(3,023 Views)
Use this function it can be usefull.

int FakeKeystroke (int Keycode);

This function simulates a keystroke by posting a keystroke event to the currently
active panel.

This function has the same effect as actually pressing a key at the keyboard.

Note: The order in which the fake keystroke is received in relation to other
events is not defined, so you must use this function with care.

Find the function panel in the user interface library

Hope it helps.
Image Hosted by ImageShack.us
0 Kudos
Message 2 of 3
(3,023 Views)
Hi All

fixed this problem in the end by using the timer function call to
generate a tick every second.
The timer procedure checks a gobal varible to see if a function should
be called


"Xavier Caparrós" wrote:
>
> Use this function it can be usefull.
>
> int FakeKeystroke (int Keycode);
>
> This function simulates a keystroke by posting a keystroke event to the currently
> active panel.
>
> This function has the same effect as actually pressing a key at the keyboard.
>
> Note: The order in which the fake keystroke is received in relation to other
> events is not defined, so you must use this function with care.
>
> Find the function panel in the user interface library
>
> Hope it helps.

--
Brian Laffoley
Development Eng
0 Kudos
Message 3 of 3
(3,023 Views)