<br>
Hi,

LabVIEW itself doesn't have built-in features that will let you
simulate keyboard entries and clicks, as you may have figured out.
This can however be achieved by using a combination of tricks and
techniques.

Firstly, simulating keyboard entries is much easier than mouse-clicks.
You can use Windows' shell scripting to issue various commands -- the
<b>AppActivate</b> command to activate your application.  And then
there's the <b>SendKeys</b> command which simulates keystrokes.

Second response on the following thread has such example scripts and
other details:

http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=135&HOID=506500000008000000C2860000&UCATEGORY_0=_9_&UCATEGORY_S=0&USEARCHCONTEXT_QUESTION_0=sendkey&USEARCHCONTEXT_QUESTION_S=0

You can run these and such scripts from within LabVIEW using the
SystemExec VI.  In fact you can generate the script on the fly using
string functions in LabVIEW, if you wish.

Secondly, the following thread has a simulate_keyboard VI which
directly calls into Windows DLL to simulate keyboard entries.  You may
use this VI as well to generate keystrokes.

http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=135&HOID=5065000000080000009DBE0000&UCATEGORY_0=_49_%24_6_&UCATEGORY_S=0&USEARCHCONTEXT_QUESTION_0=sendkey&USEARCHCONTEXT_QUESTION_S=0

Hope this gives you some ideas.

<i>Khalid</i><p>

Reply via email to