Jump to content

sending blocks of text


Recommended Posts

Hi

Im piecing together a little app that when a button is clicked will dump a paragraph of text into an open telnet session

I know I can use the send function to send it a keystroke at a time or use ClipPut() to dump it tot eh clipboard then send ctrl V to paste it but would rather not use this as it would overwrite anything currently in the clipboard

is there another method of doing this ?

thanks

Grant

Link to comment
Share on other sites

ControlSetText() if it was a control, but im doubting it is if your telneting.

Try something like...

$text = "Your large block of text goes here"

$clipboard = ClipGet(); get current clipboard data

ClipPut($text) ; put your large block to clipboard
Send("CTRL+V") ; or controlsend() ; send to telent session
ClipPut($clipboard) ; replace clipboard as if nothing happend.

S

They call me MrRegExpMan

Link to comment
Share on other sites

Something like this maybe

Func _PasteText($SText)
    $var = ClipGet()
    ;code to gety your text
    ;code to send text to telnet
    ClipPut($var)
EndFunc

Edit: beaten to it.

Edited by JohnOne

AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...