25.10.2014 Views

are registered trademarks, the Attachmate logo is a trademark and

are registered trademarks, the Attachmate logo is a trademark and

are registered trademarks, the Attachmate logo is a trademark and

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

WINHLLAPI LANGUAGE REFERENCE<br />

An application program must pass <strong>the</strong> following parameters when calling th<strong>is</strong><br />

function:<br />

Function 3<br />

Data string<br />

A string of maximum 255 characters (keystrokes)to be sent to <strong>the</strong> host PS.<br />

The string must end with an EOT character if STREOT <strong>is</strong> set in Function 9.<br />

Data length The string length. Overridden if STREOT <strong>is</strong> set in Function 9.<br />

PS position<br />

Reserved.<br />

Return parameters<br />

Result code<br />

Function replaces <strong>the</strong> value of call parameter PS position with one of <strong>the</strong> following<br />

codes:<br />

Code<br />

Description<br />

0 The function was successful.<br />

1 The application was not connected with a host PS.<br />

2 An incorrect parameter was entered.<br />

4 Host session was busy; not all keystrokes were sent.<br />

5 Host session was inhibited, not all keystrokes were sent.<br />

9 A system error occurred.<br />

Example<br />

Notes<br />

WORD HllFunc = 3;<br />

char HllDataStr[10];<br />

/* Send "Hello" followed by Enter keystroke */<br />

strcpy (HllDataStr, "Hello@E");<br />

/* Length of data including Escape character */<br />

WORD HllDataLgth = 7;<br />

WORD PsPos;<br />

WinHLLAPI(&HllFunc, HllDataStr, &HllDataLgth, &PsPos);<br />

• For increased performance, an application may send entire strings using<br />

Function 33, “Copy String to Field,” or Function 15, “Copy String to<br />

Presentation Space,” ra<strong>the</strong>r than using th<strong>is</strong> function; however, only function 3<br />

may send special control keys.<br />

• If <strong>the</strong> keystroke string <strong>is</strong> longer than 255 characters (which <strong>is</strong> <strong>the</strong> Send Key<br />

function’s limit), use multiple calls to <strong>the</strong> Send Key function.<br />

Prep<strong>are</strong>d by <strong>Attachmate</strong> Technical Support 17

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!