View previous topic :: View next topic
|
Author |
Message |
Richard Booth
New User
Joined: 15 Oct 2009 Posts: 2 Location: Tankersley
|
|
|
|
Hi,
I am writing an interface from VBA excel to Mainframe PCOMM V5.9
Everything works fine except
autECLPSObj.SendKeys "Logon [Enter]"
The macro runs, does not fail just appears to not sent the characters and carries on the next line.
If I use other commands in the VBA script, they work on the Screen session fine
i.e. autECLPSObj.SetCursorPos 23, 39 works
so I know the VBA is talking to the screen.
Any help would be appreciated[/quote] |
|
Back to top |
|
|
mrgnndhmk
New User
Joined: 01 Feb 2006 Posts: 51 Location: India
|
|
|
|
Did you check if your session is configured with ENTER key? By default it uses CTRL for the function of CR+LF
~Muruganandham |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
autECLPSObj.SendKeys "Logon [Enter]"
the statement will send the logical enter, it is not relevant to which key the enter is assigned
a script is able to send also functions not currently mapped to any key |
|
Back to top |
|
|
mrgnndhmk
New User
Joined: 01 Feb 2006 Posts: 51 Location: India
|
|
|
|
Yes. Sendkeys would send the logical function irrespective the of the mapped keys.
But the terminal can work only with the mapped keys.
Quote: |
autECLPSObj.SendKeys "Logon [Enter]"
The macro runs, does not fail just appears to not sent the characters and carries on the next line. |
As per the result, when [ENTER], is given it goes to the next line instead of sending PF Key.
In PCOMM, [ENTER] key is mapped to [NEXT LINE] (NL) by default. It should be mapped to [CTRL ENTER]. I have faced this issue by myself
~Muruganandham k |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
Muruganandham... did You read and understand the issue ?
the TS complained about sending from a script,
not about entering data and sending the enter key from the keyboard |
|
Back to top |
|
|
mrgnndhmk
New User
Joined: 01 Feb 2006 Posts: 51 Location: India
|
|
|
|
Ok now I understand. I misread the statement
Quote: |
carries on the next line |
- my bad.
The script is perfectly alright. If the user does the same command manually "Logon [ENTER]" using the keyboard he can find something I hope.
I again tested the code in my mainframe with the same command it worked perfectly for me. |
|
Back to top |
|
|
|