Sending command keys via telnetsend

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
ronin
Newbie
Posts: 3
Joined: Thu Sep 27, 2012 9:46 am

Sending command keys via telnetsend

Post by ronin » Thu Sep 27, 2012 12:11 pm

Hi all,

I'm new to the forums, but have often read useful threads already, I am using Macro Scheduler 11 and am still surprised by its usefullness.

I decided to write apost because I am at a standstill in a script and decided to ask for help.

I need to send strings to a terminal application, it is an AS/400 application.
The first issue is error handling,when sending those strings and pressing enter an error could occur.
I have tried with Image recognition, and with textout and in general both scripts work, the difficulty I have is with the speed, it needs to be capable to transmit 10000 strings ,with 10-22 characters each, in about 10 minutes.
So I expermimented with telnetsend and in terms of speed it looks to be fine, also the response gives me the error code in a string.But to react on those errors is where I have the difficulty.
Long story short, I need to send command keys like F3,F12 and F23 via telnetsend but see it's sent as string, also VK doesn't work. Is there a way/code to accomplish this?

Thanks in advance.
“Do nothing that is of no useâ€

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Thu Sep 27, 2012 12:34 pm

I think the answer can be found here:

http://aperiodic.net/phil/archives/Geek ... -keys.html

When you send a function key telnet actually sends a string which is an "escape code". E.g. according to the above link you would send string "^[[24~" to "press" F12.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

ronin
Newbie
Posts: 3
Joined: Thu Sep 27, 2012 9:46 am

Post by ronin » Thu Sep 27, 2012 1:45 pm

wow, that was fast.I'll try that, thanks :D
“Do nothing that is of no useâ€

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts