MrSnugglez Posted May 31, 2008 Posted May 31, 2008 Topic says it all. Im trying to learn autoit and right now im wanting to learn how to send data around thats in the clipboard. Right now the paste function Send("^v") is what i use to put data into a window or something to get the data from the clipboard. The problem is that alot of times it wont paste and missess or something. I dont know. Can anyone recommend better code for such an action?
mysterious Posted May 31, 2008 Posted May 31, 2008 (edited) Use FileWrite() ******************** !TAKEN FROM HELP FILE! $file = FileOpen("test.txt", 1) ; Check if file opened for writing OK If $file = -1 Then MsgBox(0, "Error", "Unable to open file.") Exit EndIf FileWrite($file, "Line1") FileWrite($file, "Still Line1" & @CRLF) FileWrite($file, "Line2") FileClose($file) It works great, and the file does not have to be open, it does it by itself. PM if you need a more in depth description of that. Good luck! Edited May 31, 2008 by mysterious [center]Class... Now in session ( Thanks to Valuater )Not much more you need to know. ^_^[/center]
MrSnugglez Posted May 31, 2008 Author Posted May 31, 2008 Use FileWrite() ******************** !TAKEN FROM HELP FILE! $file = FileOpen("test.txt", 1) ; Check if file opened for writing OK If $file = -1 Then MsgBox(0, "Error", "Unable to open file.") Exit EndIf FileWrite($file, "Line1") FileWrite($file, "Still Line1" & @CRLF) FileWrite($file, "Line2") FileClose($file) It works great, and the file does not have to be open, it does it by itself. PM if you need a more in depth description of that. Good luck! Thanks that seems like it will fix writing directly to a file. What Im trying to do is write to differant windows. Like say paste a website to my broswer, or open my aim and paste something to a window where im chatting to a friend. Im not sure writing to a file could help with that.
mysterious Posted May 31, 2008 Posted May 31, 2008 I see what you mean, there is commands for that, like ShellExecute() Well, I'm tired ill see what I can do tomorrow, check the help file for that, though. Good luck. [center]Class... Now in session ( Thanks to Valuater )Not much more you need to know. ^_^[/center]
BrettF Posted May 31, 2008 Posted May 31, 2008 (edited) mysterious, what are you on about... The functions you need are: ClipGet ( ) ControlSend () EDIT: Spelling. Edited May 31, 2008 by Bert Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version!
MrSnugglez Posted May 31, 2008 Author Posted May 31, 2008 mysterious, what are you on about... The functions you need are:ClipGet ( )ControlSend ()EDIT: Spelling.Thank you I will take a closer look at these
mysterious Posted May 31, 2008 Posted May 31, 2008 mysterious, what are you on about... The functions you need are:ClipGet ( )ControlSend ()EDIT: Spelling.He said, "Paste a website to my browser"... [center]Class... Now in session ( Thanks to Valuater )Not much more you need to know. ^_^[/center]
BrettF Posted May 31, 2008 Posted May 31, 2008 And ShellExecute() is a command for pasting to a browser? Since when? Have I missed something? Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version!
BLuFeNiX Posted May 31, 2008 Posted May 31, 2008 And ShellExecute() is a command for pasting to a browser? Since when? Have I missed something?I was wondering the same thing.. *confused* http://blufenix.net
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now