bangity Posted May 25, 2006 Posted May 25, 2006 I used MouseClickDrag and dragged over a string. then i used Send("^c") to let it click Ctrl + C to put the string in the clipboard. after that, i used $a = ClipGet() but then when i try to msgbox it out. there was nothing. how is this wrong? is it ^c??
bangity Posted May 25, 2006 Author Posted May 25, 2006 ok, very simple. "This is a string" MouseClickDrag("left", "$x1", "$y1", "$x2", "$y2") Send("^c") $str = ClipGet() just want to put the dragged string into the clipboard!
nfwu Posted May 25, 2006 Posted May 25, 2006 Why don't you use ControlGetText() instead? #) TwitterOut of date stuff:Scripts: Sudoku Solver | Webserver | 3D library (Pure AutoIt) | Wood's GadgetsUDFs: _WoodUniqueID() | _DialogEditIni() | _Console*() | _GetIPConfigData() | _URLEncode/Decode()
bangity Posted May 25, 2006 Author Posted May 25, 2006 no, what i mean is, in a website. there are many text. what i want is to start dragging from a position and drag over to the end of the text. Then put that text inside a clipboard so i can paste it into a variable for other purposes! any idea around?
JoshDB Posted May 26, 2006 Posted May 26, 2006 Your code should be working... What errors does it throw out? Ha, I haven't been on these forums since... 2006, almost. Behold, my legacy signature:My AutoIt idol is Valuater. You know you love him, too.My Stuff: D&D AGoT Tools Suite
bangity Posted May 26, 2006 Author Posted May 26, 2006 it didn't say any error. the problem is there is nothing in the Clipboard after i used Send("^c")!
bear Posted May 26, 2006 Posted May 26, 2006 it didn't say any error. the problem is there is nothing in the Clipboard after i used Send("^c")!do you use ctrl + c in ie?i tried that by using Win32::GUITest (a perl package) SendKeys('^c');just like your situation, nothing happended!i also tried keybd_event function in C/C++ to simulate Ctrl + C in ie, but no result.i don't try to use AutoIt3 to do that, but i think it will be the same.finally, i have no choice, so i use menu command to enforce ie to copy that string.send %ec to do that...
bangity Posted June 2, 2006 Author Posted June 2, 2006 what is %ec? what do you mean? i also tried to use right click and click copy after it dragged over the string., but then there was nothing in the clipboard. i really need this help please!
nfwu Posted June 2, 2006 Posted June 2, 2006 How about trying Dale's IE Library? #) TwitterOut of date stuff:Scripts: Sudoku Solver | Webserver | 3D library (Pure AutoIt) | Wood's GadgetsUDFs: _WoodUniqueID() | _DialogEditIni() | _Console*() | _GetIPConfigData() | _URLEncode/Decode()
Bert Posted June 2, 2006 Posted June 2, 2006 I've ran into this problem also, and what I did was tried pasting it to the clipboard several times in a row with short sleep statements between. I know there are many people who say this is a bad idea, but it did fix the problem. For those who wish to slam me to the curb...... The Vollatran project  My blog: http://www.vollysinterestingshit.com/
exodius Posted June 2, 2006 Posted June 2, 2006 Is there any way that you could just download the page using Inetget and parse out the part of it that you want?
neogia Posted June 2, 2006 Posted June 2, 2006 (edited) I've had some problems with the clipboard in the past, and this is what I've done:ClipPut("") Send("^c") $clip = ClipGet() While $cip == "" $clip = ClipGet() WEndI know it's longer, but it's usually that the contents just haven't been put into the clipboard by the time AutoIt gets to the next line, and tries to read it.Edit:Not at all. We all make typos Edited June 2, 2006 by neogia [u]My UDFs[/u]Coroutine Multithreading UDF LibraryStringRegExp GuideRandom EncryptorArrayToDisplayString"The Brain, expecting disaster, fails to find the obvious solution." -- neogia
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