TeWindow("TeWindow").TeScreen("Member Units").SendKey TE_ENTER
The above works fine but it doesn't work when I tried to parametrize it by passing the value from the data table like below:
TeWindow("TeWindow").TeScreen("Member Units").SendKey dataTable("KeyClick",dtLocalSheet)
I put TE_ENTER in the KeyClick column for the action local sheet.
I have similar scenario and as a workaround I am using select statement.
Public Function TeSendKey(KeyName)
Select Case lcase(KeyName)
I see that you created a Function , so does your function works on any page(screen)?
i.e. does the below works for any screen? Also why do you need a sync after pressing each key?
<font class="small">Code:</font><hr /><pre>
TeWindow("protocol:=5250").TeScreen("micclass:=TeS creen").Sendkey TE_ENTER
I guess you've been working with AS400 for some time , for me I just started and I found it challenge , for example I have to use "/" to select a radio button and I have to use the up and down cursors to move to the object I want to interact with.
Thanks Reddy , I guess I will need your help when I get deeper in AS400 automation [img]/images/graemlins/smile.gif[/img]
[/ QUOTE ]
This works for me on all the screens and sending key will take sometime(in my application) to refresh screen or navigate to new screen, this is like browser refresh or click something on the browser. I am working on Z\OS(protocol - 3270).